<!DOCTYPE html>
<html lang="zh-CN" dir="ltr">
  <head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width,initial-scale=1">
    <title>站点配置 | 九州通物流</title>
    <meta name="description" content="Vite & Vue 驱动的静态站点生成器">
    <link rel="preload stylesheet" href="/assets/style.67ec958e.css" as="style">
    
    <script type="module" src="/assets/app.434eb1a6.js"></script>
    <link rel="preload" href="/assets/inter-roman-latin.2ed14f66.woff2" as="font" type="font/woff2" crossorigin="">
    <link rel="modulepreload" href="/assets/chunks/framework.6167f762.js">
    <link rel="modulepreload" href="/assets/chunks/theme.fed2e9e6.js">
    <link rel="modulepreload" href="/assets/chunks/ComponentInHeader.3eef76ce.js">
    <link rel="modulepreload" href="/assets/chunks/ModalDemo.7f334039.js">
    <link rel="modulepreload" href="/assets/chunks/button.c8413dcd.js">
    <link rel="modulepreload" href="/assets/examples_md_site-config.md.b89a013d.lean.js">
    <link rel="icon" href="//logo.ico">
    <meta name="google-site-verification" content="Wzz07XeBKMnNRNwUcsw6hEgpGoTkggTxORUtLRm6rns">
    <script id="check-dark-mode">(()=>{const e=localStorage.getItem("vitepress-theme-appearance")||"auto",a=window.matchMedia("(prefers-color-scheme: dark)").matches;(!e||e==="auto"?a:e==="dark")&&document.documentElement.classList.add("dark")})();</script>
    <script id="check-mac-os">document.documentElement.classList.toggle("mac",/Mac|iPhone|iPod|iPad/i.test(navigator.platform));</script>
  </head>
  <body>
    <div id="app"><div class="Layout" data-v-5a346dfe><!--[--><!--]--><!--[--><span tabindex="-1" data-v-0f60ec36></span><a href="#VPContent" class="VPSkipLink visually-hidden" data-v-0f60ec36> Skip to content </a><!--]--><!----><header class="VPNav" data-v-5a346dfe data-v-ae24b3ad><div class="VPNavBar has-sidebar" data-v-ae24b3ad data-v-a0fd61f4><div class="container" data-v-a0fd61f4><div class="title" data-v-a0fd61f4><div class="VPNavBarTitle has-sidebar" data-v-a0fd61f4 data-v-86d1bed8><a class="title" href="/" data-v-86d1bed8><!--[--><!--]--><!--[--><img class="VPImage logo" src="/logo.ico" alt data-v-8426fc1a><!--]--><!--[-->云仓组件库<!--]--><!--[--><!--]--></a></div></div><div class="content" data-v-a0fd61f4><div class="curtain" data-v-a0fd61f4></div><div class="content-body" data-v-a0fd61f4><!--[--><!--]--><div class="VPNavBarSearch search" data-v-a0fd61f4><!--[--><!----><div id="local-search"><button type="button" class="DocSearch DocSearch-Button" aria-label="Search"><span class="DocSearch-Button-Container"><svg class="DocSearch-Search-Icon" width="20" height="20" viewBox="0 0 20 20" aria-label="search icon"><path d="M14.386 14.386l4.0877 4.0877-4.0877-4.0877c-2.9418 2.9419-7.7115 2.9419-10.6533 0-2.9419-2.9418-2.9419-7.7115 0-10.6533 2.9418-2.9419 7.7115-2.9419 10.6533 0 2.9419 2.9418 2.9419 7.7115 0 10.6533z" stroke="currentColor" fill="none" fill-rule="evenodd" stroke-linecap="round" stroke-linejoin="round"></path></svg><span class="DocSearch-Button-Placeholder">Search</span></span><span class="DocSearch-Button-Keys"><kbd class="DocSearch-Button-Key"></kbd><kbd class="DocSearch-Button-Key">K</kbd></span></button></div><!--]--></div><nav aria-labelledby="main-nav-aria-label" class="VPNavBarMenu menu" data-v-a0fd61f4 data-v-7f418b0f><span id="main-nav-aria-label" class="visually-hidden" data-v-7f418b0f>Main Navigation</span><!--[--><!--[--><a class="VPLink link VPNavBarMenuLink" href="/guide/what-is-vitepress" tabindex="0" data-v-7f418b0f data-v-42ef59de><!--[--><span data-v-42ef59de>接入指南</span><!--]--></a><!--]--><!--[--><a class="VPLink link VPNavBarMenuLink active" href="/examples/md/site-config" tabindex="0" data-v-7f418b0f data-v-42ef59de><!--[--><span data-v-42ef59de>组件配置</span><!--]--></a><!--]--><!--[--><a class="VPLink link VPNavBarMenuLink" href="/versionLog/v1.0.2" tabindex="0" data-v-7f418b0f data-v-42ef59de><!--[--><span data-v-42ef59de>版本日志</span><!--]--></a><!--]--><!--]--></nav><!----><div class="VPNavBarAppearance appearance" data-v-a0fd61f4 data-v-e6aabb21><button class="VPSwitch VPSwitchAppearance" type="button" role="switch" title="toggle dark mode" aria-checked="false" data-v-e6aabb21 data-v-ce54a7d1 data-v-b1685198><span class="check" data-v-b1685198><span class="icon" data-v-b1685198><!--[--><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" viewbox="0 0 24 24" class="sun" data-v-ce54a7d1><path d="M12,18c-3.3,0-6-2.7-6-6s2.7-6,6-6s6,2.7,6,6S15.3,18,12,18zM12,8c-2.2,0-4,1.8-4,4c0,2.2,1.8,4,4,4c2.2,0,4-1.8,4-4C16,9.8,14.2,8,12,8z"></path><path d="M12,4c-0.6,0-1-0.4-1-1V1c0-0.6,0.4-1,1-1s1,0.4,1,1v2C13,3.6,12.6,4,12,4z"></path><path d="M12,24c-0.6,0-1-0.4-1-1v-2c0-0.6,0.4-1,1-1s1,0.4,1,1v2C13,23.6,12.6,24,12,24z"></path><path d="M5.6,6.6c-0.3,0-0.5-0.1-0.7-0.3L3.5,4.9c-0.4-0.4-0.4-1,0-1.4s1-0.4,1.4,0l1.4,1.4c0.4,0.4,0.4,1,0,1.4C6.2,6.5,5.9,6.6,5.6,6.6z"></path><path d="M19.8,20.8c-0.3,0-0.5-0.1-0.7-0.3l-1.4-1.4c-0.4-0.4-0.4-1,0-1.4s1-0.4,1.4,0l1.4,1.4c0.4,0.4,0.4,1,0,1.4C20.3,20.7,20,20.8,19.8,20.8z"></path><path d="M3,13H1c-0.6,0-1-0.4-1-1s0.4-1,1-1h2c0.6,0,1,0.4,1,1S3.6,13,3,13z"></path><path d="M23,13h-2c-0.6,0-1-0.4-1-1s0.4-1,1-1h2c0.6,0,1,0.4,1,1S23.6,13,23,13z"></path><path d="M4.2,20.8c-0.3,0-0.5-0.1-0.7-0.3c-0.4-0.4-0.4-1,0-1.4l1.4-1.4c0.4-0.4,1-0.4,1.4,0s0.4,1,0,1.4l-1.4,1.4C4.7,20.7,4.5,20.8,4.2,20.8z"></path><path d="M18.4,6.6c-0.3,0-0.5-0.1-0.7-0.3c-0.4-0.4-0.4-1,0-1.4l1.4-1.4c0.4-0.4,1-0.4,1.4,0s0.4,1,0,1.4l-1.4,1.4C18.9,6.5,18.6,6.6,18.4,6.6z"></path></svg><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" viewbox="0 0 24 24" class="moon" data-v-ce54a7d1><path d="M12.1,22c-0.3,0-0.6,0-0.9,0c-5.5-0.5-9.5-5.4-9-10.9c0.4-4.8,4.2-8.6,9-9c0.4,0,0.8,0.2,1,0.5c0.2,0.3,0.2,0.8-0.1,1.1c-2,2.7-1.4,6.4,1.3,8.4c2.1,1.6,5,1.6,7.1,0c0.3-0.2,0.7-0.3,1.1-0.1c0.3,0.2,0.5,0.6,0.5,1c-0.2,2.7-1.5,5.1-3.6,6.8C16.6,21.2,14.4,22,12.1,22zM9.3,4.4c-2.9,1-5,3.6-5.2,6.8c-0.4,4.4,2.8,8.3,7.2,8.7c2.1,0.2,4.2-0.4,5.8-1.8c1.1-0.9,1.9-2.1,2.4-3.4c-2.5,0.9-5.3,0.5-7.5-1.1C9.2,11.4,8.1,7.7,9.3,4.4z"></path></svg><!--]--></span></span></button></div><div class="VPSocialLinks VPNavBarSocialLinks social-links" data-v-a0fd61f4 data-v-0394ad82 data-v-7bc22406><!--[--><a class="VPSocialLink no-icon" href="https://github.com/vanchKong/VitePressCN" aria-label="github" target="_blank" rel="noopener" data-v-7bc22406 data-v-f80f8133><svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>GitHub</title><path d="M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12"/></svg></a><!--]--></div><div class="VPFlyout VPNavBarExtra extra" data-v-a0fd61f4 data-v-40855f84 data-v-9c007e85><button type="button" class="button" aria-haspopup="true" aria-expanded="false" aria-label="extra navigation" data-v-9c007e85><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" viewbox="0 0 24 24" class="icon" data-v-9c007e85><circle cx="12" cy="12" r="2"></circle><circle cx="19" cy="12" r="2"></circle><circle cx="5" cy="12" r="2"></circle></svg></button><div class="menu" data-v-9c007e85><div class="VPMenu" data-v-9c007e85 data-v-e7ea1737><!----><!--[--><!--[--><!----><div class="group" data-v-40855f84><div class="item appearance" data-v-40855f84><p class="label" data-v-40855f84>主题</p><div class="appearance-action" data-v-40855f84><button class="VPSwitch VPSwitchAppearance" type="button" role="switch" title="toggle dark mode" aria-checked="false" data-v-40855f84 data-v-ce54a7d1 data-v-b1685198><span class="check" data-v-b1685198><span class="icon" data-v-b1685198><!--[--><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" viewbox="0 0 24 24" class="sun" data-v-ce54a7d1><path d="M12,18c-3.3,0-6-2.7-6-6s2.7-6,6-6s6,2.7,6,6S15.3,18,12,18zM12,8c-2.2,0-4,1.8-4,4c0,2.2,1.8,4,4,4c2.2,0,4-1.8,4-4C16,9.8,14.2,8,12,8z"></path><path d="M12,4c-0.6,0-1-0.4-1-1V1c0-0.6,0.4-1,1-1s1,0.4,1,1v2C13,3.6,12.6,4,12,4z"></path><path d="M12,24c-0.6,0-1-0.4-1-1v-2c0-0.6,0.4-1,1-1s1,0.4,1,1v2C13,23.6,12.6,24,12,24z"></path><path d="M5.6,6.6c-0.3,0-0.5-0.1-0.7-0.3L3.5,4.9c-0.4-0.4-0.4-1,0-1.4s1-0.4,1.4,0l1.4,1.4c0.4,0.4,0.4,1,0,1.4C6.2,6.5,5.9,6.6,5.6,6.6z"></path><path d="M19.8,20.8c-0.3,0-0.5-0.1-0.7-0.3l-1.4-1.4c-0.4-0.4-0.4-1,0-1.4s1-0.4,1.4,0l1.4,1.4c0.4,0.4,0.4,1,0,1.4C20.3,20.7,20,20.8,19.8,20.8z"></path><path d="M3,13H1c-0.6,0-1-0.4-1-1s0.4-1,1-1h2c0.6,0,1,0.4,1,1S3.6,13,3,13z"></path><path d="M23,13h-2c-0.6,0-1-0.4-1-1s0.4-1,1-1h2c0.6,0,1,0.4,1,1S23.6,13,23,13z"></path><path d="M4.2,20.8c-0.3,0-0.5-0.1-0.7-0.3c-0.4-0.4-0.4-1,0-1.4l1.4-1.4c0.4-0.4,1-0.4,1.4,0s0.4,1,0,1.4l-1.4,1.4C4.7,20.7,4.5,20.8,4.2,20.8z"></path><path d="M18.4,6.6c-0.3,0-0.5-0.1-0.7-0.3c-0.4-0.4-0.4-1,0-1.4l1.4-1.4c0.4-0.4,1-0.4,1.4,0s0.4,1,0,1.4l-1.4,1.4C18.9,6.5,18.6,6.6,18.4,6.6z"></path></svg><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" viewbox="0 0 24 24" class="moon" data-v-ce54a7d1><path d="M12.1,22c-0.3,0-0.6,0-0.9,0c-5.5-0.5-9.5-5.4-9-10.9c0.4-4.8,4.2-8.6,9-9c0.4,0,0.8,0.2,1,0.5c0.2,0.3,0.2,0.8-0.1,1.1c-2,2.7-1.4,6.4,1.3,8.4c2.1,1.6,5,1.6,7.1,0c0.3-0.2,0.7-0.3,1.1-0.1c0.3,0.2,0.5,0.6,0.5,1c-0.2,2.7-1.5,5.1-3.6,6.8C16.6,21.2,14.4,22,12.1,22zM9.3,4.4c-2.9,1-5,3.6-5.2,6.8c-0.4,4.4,2.8,8.3,7.2,8.7c2.1,0.2,4.2-0.4,5.8-1.8c1.1-0.9,1.9-2.1,2.4-3.4c-2.5,0.9-5.3,0.5-7.5-1.1C9.2,11.4,8.1,7.7,9.3,4.4z"></path></svg><!--]--></span></span></button></div></div></div><div class="group" data-v-40855f84><div class="item social-links" data-v-40855f84><div class="VPSocialLinks social-links-list" data-v-40855f84 data-v-7bc22406><!--[--><a class="VPSocialLink no-icon" href="https://github.com/vanchKong/VitePressCN" aria-label="github" target="_blank" rel="noopener" data-v-7bc22406 data-v-f80f8133><svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>GitHub</title><path d="M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12"/></svg></a><!--]--></div></div></div><!--]--><!--]--></div></div></div><!--[--><!--]--><button type="button" class="VPNavBarHamburger hamburger" aria-label="mobile navigation" aria-expanded="false" aria-controls="VPNavScreen" data-v-a0fd61f4 data-v-e5dd9c1c><span class="container" data-v-e5dd9c1c><span class="top" data-v-e5dd9c1c></span><span class="middle" data-v-e5dd9c1c></span><span class="bottom" data-v-e5dd9c1c></span></span></button></div></div></div></div><!----></header><div class="VPLocalNav reached-top" data-v-5a346dfe data-v-79c8c1df><button class="menu" aria-expanded="false" aria-controls="VPSidebarNav" data-v-79c8c1df><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" viewbox="0 0 24 24" class="menu-icon" data-v-79c8c1df><path d="M17,11H3c-0.6,0-1-0.4-1-1s0.4-1,1-1h14c0.6,0,1,0.4,1,1S17.6,11,17,11z"></path><path d="M21,7H3C2.4,7,2,6.6,2,6s0.4-1,1-1h18c0.6,0,1,0.4,1,1S21.6,7,21,7z"></path><path d="M21,15H3c-0.6,0-1-0.4-1-1s0.4-1,1-1h18c0.6,0,1,0.4,1,1S21.6,15,21,15z"></path><path d="M17,19H3c-0.6,0-1-0.4-1-1s0.4-1,1-1h14c0.6,0,1,0.4,1,1S17.6,19,17,19z"></path></svg><span class="menu-text" data-v-79c8c1df>菜单</span></button><div class="VPLocalNavOutlineDropdown" style="--vp-vh:0px;" data-v-79c8c1df data-v-1c15a60a><button data-v-1c15a60a>回到顶部</button><!----></div></div><aside class="VPSidebar" data-v-5a346dfe data-v-b00e2fdd><div class="curtain" data-v-b00e2fdd></div><nav class="nav" id="VPSidebarNav" aria-labelledby="sidebar-aria-label" tabindex="-1" data-v-b00e2fdd><span class="visually-hidden" id="sidebar-aria-label" data-v-b00e2fdd> Sidebar Navigation </span><!--[--><!--]--><!--[--><div class="group" data-v-b00e2fdd><section class="VPSidebarItem level-0 has-active" data-v-b00e2fdd data-v-e31bd47b><div class="item" role="button" tabindex="0" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><h2 class="text" data-v-e31bd47b>参考</h2><!----></div><div class="items" data-v-e31bd47b><!--[--><div class="VPSidebarItem level-1 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="/examples/md/site-config" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>站点配置</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-1 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="/examples/md/frontmatter-config" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>Frontmatter 配置</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-1 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="/examples/md/runtime-api" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>Runtime API</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-1 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="/examples/md/cli" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>CLI</p><!--]--></a><!----></div><!----></div><section class="VPSidebarItem level-1" data-v-e31bd47b data-v-e31bd47b><div class="item" role="button" tabindex="0" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><h3 class="text" data-v-e31bd47b>默认主题</h3><!----></div><div class="items" data-v-e31bd47b><!--[--><div class="VPSidebarItem level-2 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="/examples/md/default-theme-config" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>概览</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-2 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="/examples/md/default-theme-nav" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>导航栏</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-2 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="/examples/md/default-theme-sidebar" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>侧边栏</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-2 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="/examples/md/default-theme-home-page" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>主页</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-2 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="/examples/md/default-theme-footer" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>页脚</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-2 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="/examples/md/default-theme-layout" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>布局</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-2 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="/examples/md/default-theme-badge" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>徽标</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-2 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="/examples/md/default-theme-team-page" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>团队</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-2 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="/examples/md/default-theme-prev-next-links" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>上（下）一篇</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-2 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="/examples/md/default-theme-edit-link" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>编辑链接</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-2 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="/examples/md/default-theme-last-updated" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>最近更新时间</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-2 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="/examples/md/default-theme-search" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>搜索</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-2 is-link" data-v-e31bd47b data-v-e31bd47b><div class="item" data-v-e31bd47b><div class="indicator" data-v-e31bd47b></div><a class="VPLink link link" href="/examples/md/default-theme-carbon-ads" data-v-e31bd47b><!--[--><p class="text" data-v-e31bd47b>Carbon Ads</p><!--]--></a><!----></div><!----></div><!--]--></div></section><!--]--></div></section></div><!--]--><!--[--><!--]--></nav></aside><div class="VPContent has-sidebar" id="VPContent" data-v-5a346dfe data-v-669faec9><div class="VPDoc has-sidebar has-aside" data-v-669faec9 data-v-6b87e69f><!--[--><!--]--><div class="container" data-v-6b87e69f><div class="aside" data-v-6b87e69f><div class="aside-curtain" data-v-6b87e69f></div><div class="aside-container" data-v-6b87e69f><div class="aside-content" data-v-6b87e69f><div class="VPDocAside" data-v-6b87e69f data-v-3f215769><!--[--><!--]--><!--[--><!--]--><div class="VPDocAsideOutline" role="navigation" data-v-3f215769 data-v-d330b1bb><div class="content" data-v-d330b1bb><div class="outline-marker" data-v-d330b1bb></div><div class="outline-title" role="heading" aria-level="2" data-v-d330b1bb>当前页</div><nav aria-labelledby="doc-outline-aria-label" data-v-d330b1bb><span class="visually-hidden" id="doc-outline-aria-label" data-v-d330b1bb> Table of Contents for current page </span><ul class="root" data-v-d330b1bb data-v-d0ee3533><!--[--><!--]--></ul></nav></div></div><!--[--><!--]--><div class="spacer" data-v-3f215769></div><!--[--><!--]--><!----><!--[--><!--]--><!--[--><!--]--></div></div></div></div><div class="content" data-v-6b87e69f><div class="content-container" data-v-6b87e69f><!--[--><!--]--><!----><main class="main" data-v-6b87e69f><div style="position:relative;" class="vp-doc _examples_md_site-config external-link-icon-enabled" data-v-6b87e69f><div><h1 id="site-config" tabindex="-1">站点配置 <a class="header-anchor" href="#site-config" aria-label="Permalink to &quot;站点配置 {#site-config}&quot;">​</a></h1><p>Site config 可以定义站点的全局设置。App config 配置选项适用于每个 VitePress 站点，无论它使用什么主题。例如 base 目录或网站的标题。</p><h2 id="overview" tabindex="-1">概览 <a class="header-anchor" href="#overview" aria-label="Permalink to &quot;概览 {#overview}&quot;">​</a></h2><h3 id="config-resolution" tabindex="-1">配置解析 <a class="header-anchor" href="#config-resolution" aria-label="Permalink to &quot;配置解析 {#config-resolution}&quot;">​</a></h3><p>配置文件总是从 <code>&lt;root&gt;/.vitepress/config.[ext]</code> 解析，其中 <code>&lt;root&gt;</code> 是你的 VitePress <a href="./../../guide/routing#root-and-source-directory">项目根目录</a>，<code>[ext]</code> 是支持的文件扩展名之一。开箱即用地支持 TypeScript。支持的扩展名包括 <code>.js</code>、<code>.ts</code>、<code>.cjs</code>、<code>.mjs</code>、<code>.cts</code> 和 <code>.mts</code>。</p><p>建议在配置文件中使用 ES 模块语法。配置文件应该默认导出一个对象：</p><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">  </span><span style="color:#6A737D;">// app level config options</span></span>
<span class="line"><span style="color:#E1E4E8;">  lang: </span><span style="color:#9ECBFF;">&#39;en-US&#39;</span><span style="color:#E1E4E8;">,</span></span>
<span class="line"><span style="color:#E1E4E8;">  title: </span><span style="color:#9ECBFF;">&#39;VitePress&#39;</span><span style="color:#E1E4E8;">,</span></span>
<span class="line"><span style="color:#E1E4E8;">  description: </span><span style="color:#9ECBFF;">&#39;Vite &amp; Vue powered static site generator.&#39;</span><span style="color:#E1E4E8;">,</span></span>
<span class="line"><span style="color:#E1E4E8;">  </span><span style="color:#F97583;">...</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">  </span><span style="color:#6A737D;">// app level config options</span></span>
<span class="line"><span style="color:#24292E;">  lang: </span><span style="color:#032F62;">&#39;en-US&#39;</span><span style="color:#24292E;">,</span></span>
<span class="line"><span style="color:#24292E;">  title: </span><span style="color:#032F62;">&#39;VitePress&#39;</span><span style="color:#24292E;">,</span></span>
<span class="line"><span style="color:#24292E;">  description: </span><span style="color:#032F62;">&#39;Vite &amp; Vue powered static site generator.&#39;</span><span style="color:#24292E;">,</span></span>
<span class="line"><span style="color:#24292E;">  </span><span style="color:#D73A49;">...</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br><span class="line-number">6</span><br><span class="line-number">7</span><br></div></div><h3 id="config-intellisense" tabindex="-1">配置智能提示 <a class="header-anchor" href="#config-intellisense" aria-label="Permalink to &quot;配置智能提示 {#config-intellisense}&quot;">​</a></h3><p>使用 <code>defineConfig</code> 辅助函数将为配置选项提供 TypeScript 支持的智能提示。假设你的 IDE 支持它，那么智能提示在 JavaScript 和 TypeScript 中都将触发。</p><div class="language-js vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">js</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">import</span><span style="color:#E1E4E8;"> { defineConfig } </span><span style="color:#F97583;">from</span><span style="color:#E1E4E8;"> </span><span style="color:#9ECBFF;">&#39;vitepress&#39;</span></span>
<span class="line"></span>
<span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">defineConfig</span><span style="color:#E1E4E8;">({</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#6A737D;">// ...</span></span>
<span class="line"><span style="color:#E1E4E8;">})</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">import</span><span style="color:#24292E;"> { defineConfig } </span><span style="color:#D73A49;">from</span><span style="color:#24292E;"> </span><span style="color:#032F62;">&#39;vitepress&#39;</span></span>
<span class="line"></span>
<span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">defineConfig</span><span style="color:#24292E;">({</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#6A737D;">// ...</span></span>
<span class="line"><span style="color:#24292E;">})</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br></div></div><h3 id="typed-theme-config" tabindex="-1">主题类型提示 <a class="header-anchor" href="#typed-theme-config" aria-label="Permalink to &quot;主题类型提示 {#typed-theme-config}&quot;">​</a></h3><p>默认情况下，<code>defineConfig</code> 辅助函数期望默认主题的主题配置数据类型：</p><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">import</span><span style="color:#E1E4E8;"> { defineConfig } </span><span style="color:#F97583;">from</span><span style="color:#E1E4E8;"> </span><span style="color:#9ECBFF;">&#39;vitepress&#39;</span></span>
<span class="line"></span>
<span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">defineConfig</span><span style="color:#E1E4E8;">({</span></span>
<span class="line"><span style="color:#E1E4E8;">	themeConfig: {</span></span>
<span class="line"><span style="color:#E1E4E8;">		</span><span style="color:#6A737D;">// Type is `DefaultTheme.Config`</span></span>
<span class="line"><span style="color:#E1E4E8;">	},</span></span>
<span class="line"><span style="color:#E1E4E8;">})</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">import</span><span style="color:#24292E;"> { defineConfig } </span><span style="color:#D73A49;">from</span><span style="color:#24292E;"> </span><span style="color:#032F62;">&#39;vitepress&#39;</span></span>
<span class="line"></span>
<span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">defineConfig</span><span style="color:#24292E;">({</span></span>
<span class="line"><span style="color:#24292E;">	themeConfig: {</span></span>
<span class="line"><span style="color:#24292E;">		</span><span style="color:#6A737D;">// Type is `DefaultTheme.Config`</span></span>
<span class="line"><span style="color:#24292E;">	},</span></span>
<span class="line"><span style="color:#24292E;">})</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br><span class="line-number">6</span><br><span class="line-number">7</span><br></div></div><p>如果你使用自定义主题并希望对主题配置进行类型检查，则需要改用 <code>defineConfigWithTheme</code>，并通过通用参数传递自定义主题的配置类型：</p><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">import</span><span style="color:#E1E4E8;"> { defineConfigWithTheme } </span><span style="color:#F97583;">from</span><span style="color:#E1E4E8;"> </span><span style="color:#9ECBFF;">&#39;vitepress&#39;</span></span>
<span class="line"><span style="color:#F97583;">import</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">type</span><span style="color:#E1E4E8;"> { ThemeConfig } </span><span style="color:#F97583;">from</span><span style="color:#E1E4E8;"> </span><span style="color:#9ECBFF;">&#39;your-theme&#39;</span></span>
<span class="line"></span>
<span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">defineConfigWithTheme</span><span style="color:#E1E4E8;">&lt;</span><span style="color:#B392F0;">ThemeConfig</span><span style="color:#E1E4E8;">&gt;({</span></span>
<span class="line"><span style="color:#E1E4E8;">	themeConfig: {</span></span>
<span class="line"><span style="color:#E1E4E8;">		</span><span style="color:#6A737D;">// Type is `ThemeConfig`</span></span>
<span class="line"><span style="color:#E1E4E8;">	},</span></span>
<span class="line"><span style="color:#E1E4E8;">})</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">import</span><span style="color:#24292E;"> { defineConfigWithTheme } </span><span style="color:#D73A49;">from</span><span style="color:#24292E;"> </span><span style="color:#032F62;">&#39;vitepress&#39;</span></span>
<span class="line"><span style="color:#D73A49;">import</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">type</span><span style="color:#24292E;"> { ThemeConfig } </span><span style="color:#D73A49;">from</span><span style="color:#24292E;"> </span><span style="color:#032F62;">&#39;your-theme&#39;</span></span>
<span class="line"></span>
<span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">defineConfigWithTheme</span><span style="color:#24292E;">&lt;</span><span style="color:#6F42C1;">ThemeConfig</span><span style="color:#24292E;">&gt;({</span></span>
<span class="line"><span style="color:#24292E;">	themeConfig: {</span></span>
<span class="line"><span style="color:#24292E;">		</span><span style="color:#6A737D;">// Type is `ThemeConfig`</span></span>
<span class="line"><span style="color:#24292E;">	},</span></span>
<span class="line"><span style="color:#24292E;">})</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br><span class="line-number">6</span><br><span class="line-number">7</span><br><span class="line-number">8</span><br></div></div><h3 id="vite-vue-markdown-config" tabindex="-1">Vite, Vue &amp; Markdown Config <a class="header-anchor" href="#vite-vue-markdown-config" aria-label="Permalink to &quot;Vite, Vue &amp; Markdown Config&quot;">​</a></h3><ul><li><p><strong>Vite</strong></p><p>你可以使用 VitePress 配置中的 <a href="#vite">vite</a> 选项配置底层 Vite 实例。无需创建单独的 Vite 配置文件。</p></li><li><p><strong>Vue</strong></p><p>VitePress 已经包含 Vite 的官方 Vue 插件（<a href="https://github.com/vitejs/vite-plugin-vue" target="_blank" rel="noreferrer">@vitejs/plugin-vue</a>）。你可以配置 VitePress 中的 <a href="#vue">vue</a> 选项。</p></li><li><p><strong>Markdown</strong></p><p>你可以使用 VitePress 配置中的 <a href="#markdown">markdown</a> 选项配置底层的 <a href="https://github.com/markdown-it/markdown-it" target="_blank" rel="noreferrer">Markdown-It</a> 实例。</p></li></ul><h2 id="site-metadata" tabindex="-1">站点元数据 <a class="header-anchor" href="#site-metadata" aria-label="Permalink to &quot;站点元数据 {#site-metadata}&quot;">​</a></h2><h3 id="title" tabindex="-1">标题 <a class="header-anchor" href="#title" aria-label="Permalink to &quot;标题 {#title}&quot;">​</a></h3><ul><li>key <code>title</code></li><li>Type: <code>string</code></li><li>Default: <code>VitePress</code></li><li>每个页面可以通过 <a href="./frontmatter-config#title">frontmatter</a> 覆写</li></ul><p>网站的标题。使用默认主题时，这将显示在导航栏中。</p><p>它还将用作所有单独页面标题的默认后缀，除非定义了 <a href="#titletemplate"><code>titleTemplate</code></a>。单个页面的最终标题将是其第一个 <code>&lt;h1&gt;</code> 标题的文本内容加上的全局 <code>title</code>。例如使用以下配置和页面内容：</p><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	title: </span><span style="color:#9ECBFF;">&#39;My Awesome Site&#39;</span><span style="color:#E1E4E8;">,</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	title: </span><span style="color:#032F62;">&#39;My Awesome Site&#39;</span><span style="color:#24292E;">,</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br></div></div><div class="language-md vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">md</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#79B8FF;font-weight:bold;"># Hello</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#005CC5;font-weight:bold;"># Hello</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br></div></div><p>页面标题就是 <code>Hello | My Awesome Site</code>.</p><h3 id="titletemplate" tabindex="-1">标题模板 <a class="header-anchor" href="#titletemplate" aria-label="Permalink to &quot;标题模板 {#titletemplate}&quot;">​</a></h3><ul><li>key: <code>titleTemplate</code></li><li>Type: <code>string | boolean</code></li><li>每个页面可以通过 <a href="./frontmatter-config#titletemplate">frontmatter</a> 覆写</li></ul><p>允许自定义每个页面的标题后缀或整个标题。例如：</p><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	title: </span><span style="color:#9ECBFF;">&#39;My Awesome Site&#39;</span><span style="color:#E1E4E8;">,</span></span>
<span class="line"><span style="color:#E1E4E8;">	titleTemplate: </span><span style="color:#9ECBFF;">&#39;Custom Suffix&#39;</span><span style="color:#E1E4E8;">,</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	title: </span><span style="color:#032F62;">&#39;My Awesome Site&#39;</span><span style="color:#24292E;">,</span></span>
<span class="line"><span style="color:#24292E;">	titleTemplate: </span><span style="color:#032F62;">&#39;Custom Suffix&#39;</span><span style="color:#24292E;">,</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br></div></div><div class="language-md vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">md</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#79B8FF;font-weight:bold;"># Hello</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#005CC5;font-weight:bold;"># Hello</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br></div></div><p>页面标题就是 <code>Hello | Custom Suffix</code>.</p><p>要完全自定义标题的呈现方式，你可以在 <code>titleTemplate</code> 中使用 <code>:title</code> 标识符：</p><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	titleTemplate: </span><span style="color:#9ECBFF;">&#39;:title - Custom Suffix&#39;</span><span style="color:#E1E4E8;">,</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	titleTemplate: </span><span style="color:#032F62;">&#39;:title - Custom Suffix&#39;</span><span style="color:#24292E;">,</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br></div></div><p>这里的 <code>:title</code> 将替换为从页面的第一个 <code>&lt;h1&gt;</code> 标题推断出的文本。上一个示例页面的标题将是 <code>Hello - Custom Suffix</code>。</p><p>该选项可以设置为 <code>false</code> 以禁用标题后缀。</p><h3 id="description" tabindex="-1">描述 <a class="header-anchor" href="#description" aria-label="Permalink to &quot;描述 {#description}&quot;">​</a></h3><ul><li>key: <code>description</code></li><li>Type: <code>string</code></li><li>Default: <code>A VitePress site</code></li><li>每个页面可以通过 <a href="./frontmatter-config#description">frontmatter</a> 覆写</li></ul><p>网站的描述。这将呈现为页面 HTML 中的 <code>&lt;meta&gt;</code> 标签。</p><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	description: </span><span style="color:#9ECBFF;">&#39;A VitePress site&#39;</span><span style="color:#E1E4E8;">,</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	description: </span><span style="color:#032F62;">&#39;A VitePress site&#39;</span><span style="color:#24292E;">,</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br></div></div><h3 id="head" tabindex="-1">head <a class="header-anchor" href="#head" aria-label="Permalink to &quot;head&quot;">​</a></h3><ul><li>key: <code>head</code></li><li>Type: <code>HeadConfig[]</code></li><li>Default: <code>[]</code></li><li>每个页面可以通过 <a href="./frontmatter-config#head">frontmatter</a> 添加</li></ul><details class="details custom-block"><summary>要在页面 HTML 的 <code>&lt;head&gt;</code> 标记中呈现的其他元素。用户添加的标签在结束 <code>head</code> 标签之前呈现，在 VitePress 标签之后。</summary><p>Additional elements to render in the <code>&lt;head&gt;</code> tag in the page HTML. The user-added tags are rendered before the closing <code>head</code> tag, after VitePress tags.</p></details><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	head: [</span></span>
<span class="line"><span style="color:#E1E4E8;">		[</span></span>
<span class="line"><span style="color:#E1E4E8;">			</span><span style="color:#9ECBFF;">&#39;link&#39;</span><span style="color:#E1E4E8;">,</span></span>
<span class="line"><span style="color:#E1E4E8;">			{ rel: </span><span style="color:#9ECBFF;">&#39;preconnect&#39;</span><span style="color:#E1E4E8;">, href: </span><span style="color:#9ECBFF;">&#39;https://fonts.gstatic.com&#39;</span><span style="color:#E1E4E8;">, crossorigin: </span><span style="color:#9ECBFF;">&#39;&#39;</span><span style="color:#E1E4E8;"> },</span></span>
<span class="line"><span style="color:#E1E4E8;">			</span><span style="color:#6A737D;">// would render:</span></span>
<span class="line"><span style="color:#E1E4E8;">			</span><span style="color:#6A737D;">//</span></span>
<span class="line"><span style="color:#E1E4E8;">			</span><span style="color:#6A737D;">// &lt;link rel=&quot;preconnect&quot; href=&quot;https://fonts.gstatic.com&quot; crossorigin /&gt;</span></span>
<span class="line"><span style="color:#E1E4E8;">		],</span></span>
<span class="line"></span>
<span class="line"><span style="color:#E1E4E8;">		[</span></span>
<span class="line"><span style="color:#E1E4E8;">			</span><span style="color:#9ECBFF;">&#39;script&#39;</span><span style="color:#E1E4E8;">,</span></span>
<span class="line"><span style="color:#E1E4E8;">			{ id: </span><span style="color:#9ECBFF;">&#39;register-sw&#39;</span><span style="color:#E1E4E8;"> },</span></span>
<span class="line"><span style="color:#E1E4E8;">			</span><span style="color:#9ECBFF;">`;(() =&gt; {</span></span>
<span class="line"><span style="color:#9ECBFF;">        if (&#39;serviceWorker&#39; in navigator) {</span></span>
<span class="line"><span style="color:#9ECBFF;">          navigator.serviceWorker.register(&#39;/sw.js&#39;)</span></span>
<span class="line"><span style="color:#9ECBFF;">        }</span></span>
<span class="line"><span style="color:#9ECBFF;">      })()`</span><span style="color:#E1E4E8;">,</span></span>
<span class="line"><span style="color:#E1E4E8;">			</span><span style="color:#6A737D;">// would render:</span></span>
<span class="line"><span style="color:#E1E4E8;">			</span><span style="color:#6A737D;">//</span></span>
<span class="line"><span style="color:#E1E4E8;">			</span><span style="color:#6A737D;">// &lt;script id=&quot;register-sw&quot;&gt;</span></span>
<span class="line"><span style="color:#E1E4E8;">			</span><span style="color:#6A737D;">// ;(() =&gt; {</span></span>
<span class="line"><span style="color:#E1E4E8;">			</span><span style="color:#6A737D;">//   if (&#39;serviceWorker&#39; in navigator) {</span></span>
<span class="line"><span style="color:#E1E4E8;">			</span><span style="color:#6A737D;">//     navigator.serviceWorker.register(&#39;/sw.js&#39;)</span></span>
<span class="line"><span style="color:#E1E4E8;">			</span><span style="color:#6A737D;">//   }</span></span>
<span class="line"><span style="color:#E1E4E8;">			</span><span style="color:#6A737D;">// })()</span></span>
<span class="line"><span style="color:#E1E4E8;">			</span><span style="color:#6A737D;">// &lt;/script&gt;</span></span>
<span class="line"><span style="color:#E1E4E8;">		],</span></span>
<span class="line"><span style="color:#E1E4E8;">	],</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	head: [</span></span>
<span class="line"><span style="color:#24292E;">		[</span></span>
<span class="line"><span style="color:#24292E;">			</span><span style="color:#032F62;">&#39;link&#39;</span><span style="color:#24292E;">,</span></span>
<span class="line"><span style="color:#24292E;">			{ rel: </span><span style="color:#032F62;">&#39;preconnect&#39;</span><span style="color:#24292E;">, href: </span><span style="color:#032F62;">&#39;https://fonts.gstatic.com&#39;</span><span style="color:#24292E;">, crossorigin: </span><span style="color:#032F62;">&#39;&#39;</span><span style="color:#24292E;"> },</span></span>
<span class="line"><span style="color:#24292E;">			</span><span style="color:#6A737D;">// would render:</span></span>
<span class="line"><span style="color:#24292E;">			</span><span style="color:#6A737D;">//</span></span>
<span class="line"><span style="color:#24292E;">			</span><span style="color:#6A737D;">// &lt;link rel=&quot;preconnect&quot; href=&quot;https://fonts.gstatic.com&quot; crossorigin /&gt;</span></span>
<span class="line"><span style="color:#24292E;">		],</span></span>
<span class="line"></span>
<span class="line"><span style="color:#24292E;">		[</span></span>
<span class="line"><span style="color:#24292E;">			</span><span style="color:#032F62;">&#39;script&#39;</span><span style="color:#24292E;">,</span></span>
<span class="line"><span style="color:#24292E;">			{ id: </span><span style="color:#032F62;">&#39;register-sw&#39;</span><span style="color:#24292E;"> },</span></span>
<span class="line"><span style="color:#24292E;">			</span><span style="color:#032F62;">`;(() =&gt; {</span></span>
<span class="line"><span style="color:#032F62;">        if (&#39;serviceWorker&#39; in navigator) {</span></span>
<span class="line"><span style="color:#032F62;">          navigator.serviceWorker.register(&#39;/sw.js&#39;)</span></span>
<span class="line"><span style="color:#032F62;">        }</span></span>
<span class="line"><span style="color:#032F62;">      })()`</span><span style="color:#24292E;">,</span></span>
<span class="line"><span style="color:#24292E;">			</span><span style="color:#6A737D;">// would render:</span></span>
<span class="line"><span style="color:#24292E;">			</span><span style="color:#6A737D;">//</span></span>
<span class="line"><span style="color:#24292E;">			</span><span style="color:#6A737D;">// &lt;script id=&quot;register-sw&quot;&gt;</span></span>
<span class="line"><span style="color:#24292E;">			</span><span style="color:#6A737D;">// ;(() =&gt; {</span></span>
<span class="line"><span style="color:#24292E;">			</span><span style="color:#6A737D;">//   if (&#39;serviceWorker&#39; in navigator) {</span></span>
<span class="line"><span style="color:#24292E;">			</span><span style="color:#6A737D;">//     navigator.serviceWorker.register(&#39;/sw.js&#39;)</span></span>
<span class="line"><span style="color:#24292E;">			</span><span style="color:#6A737D;">//   }</span></span>
<span class="line"><span style="color:#24292E;">			</span><span style="color:#6A737D;">// })()</span></span>
<span class="line"><span style="color:#24292E;">			</span><span style="color:#6A737D;">// &lt;/script&gt;</span></span>
<span class="line"><span style="color:#24292E;">		],</span></span>
<span class="line"><span style="color:#24292E;">	],</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br><span class="line-number">6</span><br><span class="line-number">7</span><br><span class="line-number">8</span><br><span class="line-number">9</span><br><span class="line-number">10</span><br><span class="line-number">11</span><br><span class="line-number">12</span><br><span class="line-number">13</span><br><span class="line-number">14</span><br><span class="line-number">15</span><br><span class="line-number">16</span><br><span class="line-number">17</span><br><span class="line-number">18</span><br><span class="line-number">19</span><br><span class="line-number">20</span><br><span class="line-number">21</span><br><span class="line-number">22</span><br><span class="line-number">23</span><br><span class="line-number">24</span><br><span class="line-number">25</span><br><span class="line-number">26</span><br><span class="line-number">27</span><br><span class="line-number">28</span><br><span class="line-number">29</span><br><span class="line-number">30</span><br></div></div><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">type</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">HeadConfig</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">=</span><span style="color:#E1E4E8;"> [</span><span style="color:#79B8FF;">string</span><span style="color:#E1E4E8;">, </span><span style="color:#B392F0;">Record</span><span style="color:#E1E4E8;">&lt;</span><span style="color:#79B8FF;">string</span><span style="color:#E1E4E8;">, </span><span style="color:#79B8FF;">string</span><span style="color:#E1E4E8;">&gt;] </span><span style="color:#F97583;">|</span><span style="color:#E1E4E8;"> [</span><span style="color:#79B8FF;">string</span><span style="color:#E1E4E8;">, </span><span style="color:#B392F0;">Record</span><span style="color:#E1E4E8;">&lt;</span><span style="color:#79B8FF;">string</span><span style="color:#E1E4E8;">, </span><span style="color:#79B8FF;">string</span><span style="color:#E1E4E8;">&gt;, </span><span style="color:#79B8FF;">string</span><span style="color:#E1E4E8;">]</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">type</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">HeadConfig</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">=</span><span style="color:#24292E;"> [</span><span style="color:#005CC5;">string</span><span style="color:#24292E;">, </span><span style="color:#6F42C1;">Record</span><span style="color:#24292E;">&lt;</span><span style="color:#005CC5;">string</span><span style="color:#24292E;">, </span><span style="color:#005CC5;">string</span><span style="color:#24292E;">&gt;] </span><span style="color:#D73A49;">|</span><span style="color:#24292E;"> [</span><span style="color:#005CC5;">string</span><span style="color:#24292E;">, </span><span style="color:#6F42C1;">Record</span><span style="color:#24292E;">&lt;</span><span style="color:#005CC5;">string</span><span style="color:#24292E;">, </span><span style="color:#005CC5;">string</span><span style="color:#24292E;">&gt;, </span><span style="color:#005CC5;">string</span><span style="color:#24292E;">]</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br></div></div><h3 id="lang" tabindex="-1">语言 <a class="header-anchor" href="#lang" aria-label="Permalink to &quot;语言 {#lang}&quot;">​</a></h3><ul><li>key: <code>lang</code></li><li>Type: <code>string</code></li><li>Default: <code>en-US</code></li></ul><p>站点的 lang 属性。这将呈现为页面 HTML 中的 <code>&lt;html lang=&quot;en-US&quot;&gt;</code> 标签。</p><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	lang: </span><span style="color:#9ECBFF;">&#39;en-US&#39;</span><span style="color:#E1E4E8;">,</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	lang: </span><span style="color:#032F62;">&#39;en-US&#39;</span><span style="color:#24292E;">,</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br></div></div><h3 id="base" tabindex="-1">base <a class="header-anchor" href="#base" aria-label="Permalink to &quot;base&quot;">​</a></h3><ul><li>key: <code>base</code></li><li>Type: <code>string</code></li><li>Default: <code>/</code></li></ul><p>站点将部署到的 base URL。如果你计划在子路径（例如 GitHub 页面）下部署站点，则需要设置此项。如果你计划将你的站点部署到 <code>https://foo.github.io/bar/</code>，那么你应该将 <code>base</code> 设置为 <code>“/bar/”</code>。它应该始终以 <code>/</code>开头和结尾。</p><p>base 会自动添加到其他选项中以 <code>/</code> 开头的所有 URL 前面，因此你只需指定一次。</p><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	base: </span><span style="color:#9ECBFF;">&#39;/base/&#39;</span><span style="color:#E1E4E8;">,</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	base: </span><span style="color:#032F62;">&#39;/base/&#39;</span><span style="color:#24292E;">,</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br></div></div><h2 id="routing" tabindex="-1">路由 <a class="header-anchor" href="#routing" aria-label="Permalink to &quot;路由 {#routing}&quot;">​</a></h2><h3 id="简洁-url-cleanurls-guide" tabindex="-1">简洁 URL {#cleanurls}../../guide/ <a class="header-anchor" href="#简洁-url-cleanurls-guide" aria-label="Permalink to &quot;简洁 URL {#cleanurls}../../guide/&quot;">​</a></h3><ul><li>key: <code>cleanUrls</code></li><li>Type: <code>boolean</code></li><li>Default: <code>false</code></li></ul><p>当设置为 <code>true</code> 时，VitePress 将从 URL 中删除 <code>.html</code> 后缀。另请参阅<a href="./../../guide/routing#generating-clean-url">生成简洁的 URL</a>。</p><div class="warning custom-block"><p class="custom-block-title">需要服务器支持</p><p>要启用此功能，可能需要在你的托管平台上进行额外配置。要使其正常工作，你的服务器必须能够在<strong>不重定向的情况下</strong>访问 <code>/foo</code> 时提供 <code>/foo.html</code>。</p></div><h3 id="rewrites" tabindex="-1">路由重写 <a class="header-anchor" href="#rewrites" aria-label="Permalink to &quot;路由重写 {#rewrites}&quot;">​</a></h3><ul><li>key: <code>rewrites</code></li><li>Type: <code>Record&lt;string, string&gt;</code></li></ul><p>自定义目录 &lt;-&gt; URL 映射。详细信息请参阅<a href="./../../guide/routing#route-rewrites">路由：路由重写</a>。</p><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	rewrites: {</span></span>
<span class="line"><span style="color:#E1E4E8;">		</span><span style="color:#9ECBFF;">&#39;source/:page&#39;</span><span style="color:#E1E4E8;">: </span><span style="color:#9ECBFF;">&#39;destination/:page&#39;</span><span style="color:#E1E4E8;">,</span></span>
<span class="line"><span style="color:#E1E4E8;">	},</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	rewrites: {</span></span>
<span class="line"><span style="color:#24292E;">		</span><span style="color:#032F62;">&#39;source/:page&#39;</span><span style="color:#24292E;">: </span><span style="color:#032F62;">&#39;destination/:page&#39;</span><span style="color:#24292E;">,</span></span>
<span class="line"><span style="color:#24292E;">	},</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br></div></div><h2 id="build" tabindex="-1">Build <a class="header-anchor" href="#build" aria-label="Permalink to &quot;Build&quot;">​</a></h2><h3 id="srcdir" tabindex="-1">srcDir <a class="header-anchor" href="#srcdir" aria-label="Permalink to &quot;srcDir&quot;">​</a></h3><ul><li>key: <code>srcDir</code></li><li>Type: <code>string</code></li><li>Default: <code>.</code></li></ul><p>markdown 页面的目录，相对于项目根目录。另请参阅<a href="./../../guide/routing#root-and-source-directory">根目录和源目录</a>。</p><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	srcDir: </span><span style="color:#9ECBFF;">&#39;./src&#39;</span><span style="color:#E1E4E8;">,</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	srcDir: </span><span style="color:#032F62;">&#39;./src&#39;</span><span style="color:#24292E;">,</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br></div></div><h3 id="srcexclude" tabindex="-1">srcExclude <a class="header-anchor" href="#srcexclude" aria-label="Permalink to &quot;srcExclude&quot;">​</a></h3><ul><li>key: <code>srcExclude</code></li><li>Type: <code>string</code></li><li>Default: <code>undefined</code></li></ul><details class="details custom-block"><summary>用于匹配应作为源内容输出的 markdown 文件的 <a href="https://github.com/mrmlnc/fast-glob#pattern-syntax" target="_blank" rel="noreferrer">全局模式</a>。</summary><p>A <a href="https://github.com/mrmlnc/fast-glob#pattern-syntax" target="_blank" rel="noreferrer">glob pattern</a> for matching markdown files that should be excluded as source content.</p></details><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	srcExclude: [</span><span style="color:#9ECBFF;">&#39;**/README.md&#39;</span><span style="color:#E1E4E8;">, </span><span style="color:#9ECBFF;">&#39;**/TODO.md&#39;</span><span style="color:#E1E4E8;">],</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	srcExclude: [</span><span style="color:#032F62;">&#39;**/README.md&#39;</span><span style="color:#24292E;">, </span><span style="color:#032F62;">&#39;**/TODO.md&#39;</span><span style="color:#24292E;">],</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br></div></div><h3 id="outdir" tabindex="-1">outDir <a class="header-anchor" href="#outdir" aria-label="Permalink to &quot;outDir&quot;">​</a></h3><ul><li>key: <code>outDir</code></li><li>Type: <code>string</code></li><li>Default: <code>./.vitepress/dist</code></li></ul><p>项目的构建输出位置，相对于<a href="./../../guide/routing#root-and-source-directory">项目根目录</a>。</p><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	outDir: </span><span style="color:#9ECBFF;">&#39;../public&#39;</span><span style="color:#E1E4E8;">,</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	outDir: </span><span style="color:#032F62;">&#39;../public&#39;</span><span style="color:#24292E;">,</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br></div></div><h3 id="assetsdir" tabindex="-1">assetsDir <a class="header-anchor" href="#assetsdir" aria-label="Permalink to &quot;assetsDir&quot;">​</a></h3><ul><li>Type: <code>string</code></li><li>Default: <code>assets</code></li></ul><p>静态资源目录。另参阅: <a href="https://vitejs.dev/config/build-options.html#build-assetsdir" target="_blank" rel="noreferrer">assetsDir</a>.</p><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	assetsDir: </span><span style="color:#9ECBFF;">&#39;static&#39;</span><span style="color:#E1E4E8;">,</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	assetsDir: </span><span style="color:#032F62;">&#39;static&#39;</span><span style="color:#24292E;">,</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br></div></div><h3 id="cachedir" tabindex="-1">cacheDir <a class="header-anchor" href="#cachedir" aria-label="Permalink to &quot;cacheDir&quot;">​</a></h3><ul><li>key: <code>cacheDir</code></li><li>Type: <code>string</code></li><li>Default: <code>./.vitepress/cache</code></li></ul><p>缓存文件的目录，相对于<a href="./../../guide/routing#root-and-source-directory">项目根目录</a>。另请参阅：<a href="https://cn.vitejs.dev/config/shared-options" target="_blank" rel="noreferrer">vite: cacheDir</a>。</p><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	cacheDir: </span><span style="color:#9ECBFF;">&#39;./.vitepress/.vite&#39;</span><span style="color:#E1E4E8;">,</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	cacheDir: </span><span style="color:#032F62;">&#39;./.vitepress/.vite&#39;</span><span style="color:#24292E;">,</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br></div></div><h3 id="ignoredeadlinks" tabindex="-1">忽略死链 <a class="header-anchor" href="#ignoredeadlinks" aria-label="Permalink to &quot;忽略死链 {#ignoredeadlinks}&quot;">​</a></h3><ul><li>key: <code>ignoreDeadLinks</code></li><li>Type: <code>boolean | &#39;localhostLinks&#39; | (string | RegExp | ((link: string) =&gt; boolean))[]</code></li><li>Default: <code>false</code></li></ul><p>当设置为 <code>true</code> 时，VitePress 不会因为死链而导致构建失败。</p><p>当设置为 <code>&#39;localhostLinks&#39;</code> ，出现死链时构建将失败，但不会检查 <code>localhost</code> 链接。</p><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	ignoreDeadLinks: </span><span style="color:#79B8FF;">true</span><span style="color:#E1E4E8;">,</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	ignoreDeadLinks: </span><span style="color:#005CC5;">true</span><span style="color:#24292E;">,</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br></div></div><p>它也可以是一组精确的 url 字符串、正则表达式模式或自定义过滤函数。</p><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	ignoreDeadLinks: [</span></span>
<span class="line"><span style="color:#E1E4E8;">		</span><span style="color:#6A737D;">// ignore exact url &quot;/playground&quot;</span></span>
<span class="line"><span style="color:#E1E4E8;">		</span><span style="color:#9ECBFF;">&#39;/playground&#39;</span><span style="color:#E1E4E8;">,</span></span>
<span class="line"><span style="color:#E1E4E8;">		</span><span style="color:#6A737D;">// ignore all localhost links</span></span>
<span class="line"><span style="color:#E1E4E8;">		</span><span style="color:#9ECBFF;">/</span><span style="color:#F97583;">^</span><span style="color:#DBEDFF;">https</span><span style="color:#F97583;">?</span><span style="color:#DBEDFF;">:</span><span style="color:#85E89D;font-weight:bold;">\/\/</span><span style="color:#DBEDFF;">localhost</span><span style="color:#9ECBFF;">/</span><span style="color:#E1E4E8;">,</span></span>
<span class="line"><span style="color:#E1E4E8;">		</span><span style="color:#6A737D;">// ignore all links include &quot;/repl/&quot;&quot;</span></span>
<span class="line"><span style="color:#E1E4E8;">		</span><span style="color:#9ECBFF;">/</span><span style="color:#85E89D;font-weight:bold;">\/</span><span style="color:#DBEDFF;">repl</span><span style="color:#85E89D;font-weight:bold;">\/</span><span style="color:#9ECBFF;">/</span><span style="color:#E1E4E8;">,</span></span>
<span class="line"><span style="color:#E1E4E8;">		</span><span style="color:#6A737D;">// custom function, ignore all links include &quot;ignore&quot;</span></span>
<span class="line"><span style="color:#E1E4E8;">		(</span><span style="color:#FFAB70;">url</span><span style="color:#E1E4E8;">) </span><span style="color:#F97583;">=&gt;</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">			</span><span style="color:#F97583;">return</span><span style="color:#E1E4E8;"> url.</span><span style="color:#B392F0;">toLowerCase</span><span style="color:#E1E4E8;">().</span><span style="color:#B392F0;">includes</span><span style="color:#E1E4E8;">(</span><span style="color:#9ECBFF;">&#39;ignore&#39;</span><span style="color:#E1E4E8;">)</span></span>
<span class="line"><span style="color:#E1E4E8;">		},</span></span>
<span class="line"><span style="color:#E1E4E8;">	],</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	ignoreDeadLinks: [</span></span>
<span class="line"><span style="color:#24292E;">		</span><span style="color:#6A737D;">// ignore exact url &quot;/playground&quot;</span></span>
<span class="line"><span style="color:#24292E;">		</span><span style="color:#032F62;">&#39;/playground&#39;</span><span style="color:#24292E;">,</span></span>
<span class="line"><span style="color:#24292E;">		</span><span style="color:#6A737D;">// ignore all localhost links</span></span>
<span class="line"><span style="color:#24292E;">		</span><span style="color:#032F62;">/</span><span style="color:#D73A49;">^</span><span style="color:#032F62;">https</span><span style="color:#D73A49;">?</span><span style="color:#032F62;">:</span><span style="color:#22863A;font-weight:bold;">\/\/</span><span style="color:#032F62;">localhost/</span><span style="color:#24292E;">,</span></span>
<span class="line"><span style="color:#24292E;">		</span><span style="color:#6A737D;">// ignore all links include &quot;/repl/&quot;&quot;</span></span>
<span class="line"><span style="color:#24292E;">		</span><span style="color:#032F62;">/</span><span style="color:#22863A;font-weight:bold;">\/</span><span style="color:#032F62;">repl</span><span style="color:#22863A;font-weight:bold;">\/</span><span style="color:#032F62;">/</span><span style="color:#24292E;">,</span></span>
<span class="line"><span style="color:#24292E;">		</span><span style="color:#6A737D;">// custom function, ignore all links include &quot;ignore&quot;</span></span>
<span class="line"><span style="color:#24292E;">		(</span><span style="color:#E36209;">url</span><span style="color:#24292E;">) </span><span style="color:#D73A49;">=&gt;</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">			</span><span style="color:#D73A49;">return</span><span style="color:#24292E;"> url.</span><span style="color:#6F42C1;">toLowerCase</span><span style="color:#24292E;">().</span><span style="color:#6F42C1;">includes</span><span style="color:#24292E;">(</span><span style="color:#032F62;">&#39;ignore&#39;</span><span style="color:#24292E;">)</span></span>
<span class="line"><span style="color:#24292E;">		},</span></span>
<span class="line"><span style="color:#24292E;">	],</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br><span class="line-number">6</span><br><span class="line-number">7</span><br><span class="line-number">8</span><br><span class="line-number">9</span><br><span class="line-number">10</span><br><span class="line-number">11</span><br><span class="line-number">12</span><br><span class="line-number">13</span><br><span class="line-number">14</span><br></div></div><h3 id="mpa" tabindex="-1">多页应用 <!----> <a class="header-anchor" href="#mpa" aria-label="Permalink to &quot;多页应用 &lt;Badge type=&quot;warning&quot; text=&quot;experimental&quot; /&gt; {#mpa}&quot;">​</a></h3><ul><li>key: <code>mpa</code></li><li>Type: <code>boolean</code></li><li>Default: <code>false</code></li></ul><details class="details custom-block"><summary>设置为 <code>true</code> 时，生产应用程序将在 <a href="./../../guide/mpa-mode.html">MPA 模式</a>下构建。MPA 模式默认提供 零 JavaScript 支持，代价是禁用客户端导航，并且需要明确选择加入才能进行交互。</summary><p>When set to <code>true</code>, the production app will be built in <a href="./../../guide/mpa-mode">MPA Mode</a>. MPA mode ships 0kb JavaScript by default, at the cost of disabling client-side navigation and requires explicit opt-in for interactivity.</p></details><h2 id="theming" tabindex="-1">主题 <a class="header-anchor" href="#theming" aria-label="Permalink to &quot;主题 {#theming}&quot;">​</a></h2><h3 id="appearance" tabindex="-1">外观 <a class="header-anchor" href="#appearance" aria-label="Permalink to &quot;外观 {#appearance}&quot;">​</a></h3><ul><li>key: <code>appearance</code></li><li>Type: <code>boolean | &#39;dark&#39;</code></li><li>Default: <code>true</code></li></ul><p>是否启用深色模式（通过将 <code>.dark</code> 类添加到 <code>&lt;html&gt;</code> 元素）。</p><ul><li>如果该选项设置为 <code>true</code>，则默认主题将由用户的首选配色方案决定。</li><li>如果该选项设置为 <code>dark</code>，则默认情况下主题将是深色的，除非用户手动切换它。</li><li>如果该选项设置为 <code>false</code>，用户将无法切换主题。</li></ul><p>此选项注入一个内联脚本，使用 <code>vitepress-theme-appearance</code> key 从本地存储恢复用户设置。这确保在呈现页面之前应用 <code>.dark</code> 类以避免闪烁。</p><h3 id="lastupdated" tabindex="-1">最近更新时间 <a class="header-anchor" href="#lastupdated" aria-label="Permalink to &quot;最近更新时间 {#lastupdated}&quot;">​</a></h3><ul><li>key: <code>lastUpdated</code></li><li>Type: <code>boolean</code></li><li>Default: <code>false</code></li></ul><p>是否使用 Git 获取每个页面的最后更新时间戳。时间戳将包含在每个页面的页面数据中，可通过 <a href="./runtime-api#usedata"><code>useData</code></a> 访问。</p><p>使用默认主题时，启用此选项将显示每个页面的最后更新时间。你可以通过 <a href="./default-theme-config#lastupdatedtext"><code>themeConfig.lastUpdatedText</code></a> 选项自定义文本。</p><h2 id="customization" tabindex="-1">定制 <a class="header-anchor" href="#customization" aria-label="Permalink to &quot;定制 {#customization}&quot;">​</a></h2><h3 id="markdown" tabindex="-1">markdown <a class="header-anchor" href="#markdown" aria-label="Permalink to &quot;markdown&quot;">​</a></h3><ul><li>key: <code>markdown</code></li><li>Type: <code>MarkdownOption</code></li></ul><p>配置 Markdown 解析器选项。 VitePress 使用 <a href="https://github.com/markdown-it/markdown-it" target="_blank" rel="noreferrer">Markdown-it</a> 作为解析器，使用 <a href="https://shiki.matsu.io/" target="_blank" rel="noreferrer">Shiki</a> 来高亮不同语言语法。在此选项中，你可以传递各种 Markdown 相关选项以满足你的需要。</p><div class="language-js vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">js</span><pre class="shiki github-dark has-diff vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	markdown: {</span></span>
<span class="line"><span style="color:#E1E4E8;">		theme: </span><span style="color:#9ECBFF;">&#39;material-theme-palenight&#39;</span><span style="color:#E1E4E8;">,</span></span>
<span class="line"><span style="color:#E1E4E8;">		lineNumbers: </span><span style="color:#79B8FF;">true</span><span style="color:#E1E4E8;">,</span></span>
<span class="line"></span>
<span class="line"><span style="color:#E1E4E8;">		</span><span style="color:#6A737D;">// adjust how header anchors are generated,</span></span>
<span class="line"><span style="color:#E1E4E8;">		</span><span style="color:#6A737D;">// useful for integrating with tools that use different conventions</span></span>
<span class="line"><span style="color:#E1E4E8;">		anchor: {</span></span>
<span class="line"><span style="color:#E1E4E8;">			</span><span style="color:#B392F0;">slugify</span><span style="color:#E1E4E8;">(</span><span style="color:#FFAB70;">str</span><span style="color:#E1E4E8;">) {</span></span>
<span class="line"><span style="color:#E1E4E8;">				</span><span style="color:#F97583;">return</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">encodeURIComponent</span><span style="color:#E1E4E8;">(str)</span></span>
<span class="line"><span style="color:#E1E4E8;">			},</span></span>
<span class="line"><span style="color:#E1E4E8;">		},</span></span>
<span class="line"><span style="color:#E1E4E8;">	},</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light has-diff vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	markdown: {</span></span>
<span class="line"><span style="color:#24292E;">		theme: </span><span style="color:#032F62;">&#39;material-theme-palenight&#39;</span><span style="color:#24292E;">,</span></span>
<span class="line"><span style="color:#24292E;">		lineNumbers: </span><span style="color:#005CC5;">true</span><span style="color:#24292E;">,</span></span>
<span class="line"></span>
<span class="line"><span style="color:#24292E;">		</span><span style="color:#6A737D;">// adjust how header anchors are generated,</span></span>
<span class="line"><span style="color:#24292E;">		</span><span style="color:#6A737D;">// useful for integrating with tools that use different conventions</span></span>
<span class="line"><span style="color:#24292E;">		anchor: {</span></span>
<span class="line"><span style="color:#24292E;">			</span><span style="color:#6F42C1;">slugify</span><span style="color:#24292E;">(</span><span style="color:#E36209;">str</span><span style="color:#24292E;">) {</span></span>
<span class="line"><span style="color:#24292E;">				</span><span style="color:#D73A49;">return</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">encodeURIComponent</span><span style="color:#24292E;">(str)</span></span>
<span class="line"><span style="color:#24292E;">			},</span></span>
<span class="line"><span style="color:#24292E;">		},</span></span>
<span class="line"><span style="color:#24292E;">	},</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br><span class="line-number">6</span><br><span class="line-number">7</span><br><span class="line-number">8</span><br><span class="line-number">9</span><br><span class="line-number">10</span><br><span class="line-number">11</span><br><span class="line-number">12</span><br><span class="line-number">13</span><br><span class="line-number">14</span><br></div></div><p>以下是你可以在此对象中可配置的所有选项：</p><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">interface</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">MarkdownOptions</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">extends</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">MarkdownIt</span><span style="color:#E1E4E8;">.</span><span style="color:#B392F0;">Options</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#6A737D;">// Custom theme for syntax highlighting.</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#6A737D;">// You can use an existing theme.</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#6A737D;">// See: https://github.com/shikijs/shiki/blob/main/docs/themes.md#all-themes</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#6A737D;">// Or add your own theme.</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#6A737D;">// See: https://github.com/shikijs/shiki/blob/main/docs/themes.md#loading-theme</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#FFAB70;">theme</span><span style="color:#F97583;">?:</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">Shiki</span><span style="color:#E1E4E8;">.</span><span style="color:#B392F0;">IThemeRegistration</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">|</span><span style="color:#E1E4E8;"> { </span><span style="color:#FFAB70;">light</span><span style="color:#F97583;">:</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">Shiki</span><span style="color:#E1E4E8;">.</span><span style="color:#B392F0;">IThemeRegistration</span><span style="color:#E1E4E8;">; </span><span style="color:#FFAB70;">dark</span><span style="color:#F97583;">:</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">Shiki</span><span style="color:#E1E4E8;">.</span><span style="color:#B392F0;">IThemeRegistration</span><span style="color:#E1E4E8;"> }</span></span>
<span class="line"></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#6A737D;">// Enable line numbers in code block.</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#FFAB70;">lineNumbers</span><span style="color:#F97583;">?:</span><span style="color:#E1E4E8;"> </span><span style="color:#79B8FF;">boolean</span></span>
<span class="line"></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#6A737D;">// Add support for your own languages.</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#6A737D;">// https://github.com/shikijs/shiki/blob/main/docs/languages.md#supporting-your-own-languages-with-shiki</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#FFAB70;">languages</span><span style="color:#F97583;">?:</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">Shiki</span><span style="color:#E1E4E8;">.</span><span style="color:#B392F0;">ILanguageRegistration</span></span>
<span class="line"></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#6A737D;">// markdown-it-anchor plugin options.</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#6A737D;">// See: https://github.com/valeriangalliat/markdown-it-anchor#usage</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#FFAB70;">anchor</span><span style="color:#F97583;">?:</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">anchorPlugin</span><span style="color:#E1E4E8;">.</span><span style="color:#B392F0;">AnchorOptions</span></span>
<span class="line"></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#6A737D;">// markdown-it-attrs plugin options.</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#6A737D;">// See: https://github.com/arve0/markdown-it-attrs</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#FFAB70;">attrs</span><span style="color:#F97583;">?:</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">		</span><span style="color:#FFAB70;">leftDelimiter</span><span style="color:#F97583;">?:</span><span style="color:#E1E4E8;"> </span><span style="color:#79B8FF;">string</span></span>
<span class="line"><span style="color:#E1E4E8;">		</span><span style="color:#FFAB70;">rightDelimiter</span><span style="color:#F97583;">?:</span><span style="color:#E1E4E8;"> </span><span style="color:#79B8FF;">string</span></span>
<span class="line"><span style="color:#E1E4E8;">		</span><span style="color:#FFAB70;">allowedAttributes</span><span style="color:#F97583;">?:</span><span style="color:#E1E4E8;"> </span><span style="color:#79B8FF;">string</span><span style="color:#E1E4E8;">[]</span></span>
<span class="line"><span style="color:#E1E4E8;">		</span><span style="color:#FFAB70;">disable</span><span style="color:#F97583;">?:</span><span style="color:#E1E4E8;"> </span><span style="color:#79B8FF;">boolean</span></span>
<span class="line"><span style="color:#E1E4E8;">	}</span></span>
<span class="line"></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#6A737D;">// specify default language for syntax highlighter</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#FFAB70;">defaultHighlightLang</span><span style="color:#F97583;">?:</span><span style="color:#E1E4E8;"> </span><span style="color:#79B8FF;">string</span></span>
<span class="line"></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#6A737D;">// @mdit-vue/plugin-frontmatter plugin options.</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#6A737D;">// See: https://github.com/mdit-vue/mdit-vue/tree/main/packages/plugin-frontmatter#options</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#FFAB70;">frontmatter</span><span style="color:#F97583;">?:</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">FrontmatterPluginOptions</span></span>
<span class="line"></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#6A737D;">// @mdit-vue/plugin-headers plugin options.</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#6A737D;">// See: https://github.com/mdit-vue/mdit-vue/tree/main/packages/plugin-headers#options</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#FFAB70;">headers</span><span style="color:#F97583;">?:</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">HeadersPluginOptions</span></span>
<span class="line"></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#6A737D;">// @mdit-vue/plugin-sfc plugin options.</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#6A737D;">// See: https://github.com/mdit-vue/mdit-vue/tree/main/packages/plugin-sfc#options</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#FFAB70;">sfc</span><span style="color:#F97583;">?:</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">SfcPluginOptions</span></span>
<span class="line"></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#6A737D;">// @mdit-vue/plugin-toc plugin options.</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#6A737D;">// See: https://github.com/mdit-vue/mdit-vue/tree/main/packages/plugin-toc#options</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#FFAB70;">toc</span><span style="color:#F97583;">?:</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">TocPluginOptions</span></span>
<span class="line"></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#6A737D;">// Configure the Markdown-it instance.</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#B392F0;">config</span><span style="color:#F97583;">?:</span><span style="color:#E1E4E8;"> (</span><span style="color:#FFAB70;">md</span><span style="color:#F97583;">:</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">MarkdownIt</span><span style="color:#E1E4E8;">) </span><span style="color:#F97583;">=&gt;</span><span style="color:#E1E4E8;"> </span><span style="color:#79B8FF;">void</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">interface</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">MarkdownOptions</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">extends</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">MarkdownIt</span><span style="color:#24292E;">.</span><span style="color:#6F42C1;">Options</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#6A737D;">// Custom theme for syntax highlighting.</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#6A737D;">// You can use an existing theme.</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#6A737D;">// See: https://github.com/shikijs/shiki/blob/main/docs/themes.md#all-themes</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#6A737D;">// Or add your own theme.</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#6A737D;">// See: https://github.com/shikijs/shiki/blob/main/docs/themes.md#loading-theme</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#E36209;">theme</span><span style="color:#D73A49;">?:</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">Shiki</span><span style="color:#24292E;">.</span><span style="color:#6F42C1;">IThemeRegistration</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">|</span><span style="color:#24292E;"> { </span><span style="color:#E36209;">light</span><span style="color:#D73A49;">:</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">Shiki</span><span style="color:#24292E;">.</span><span style="color:#6F42C1;">IThemeRegistration</span><span style="color:#24292E;">; </span><span style="color:#E36209;">dark</span><span style="color:#D73A49;">:</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">Shiki</span><span style="color:#24292E;">.</span><span style="color:#6F42C1;">IThemeRegistration</span><span style="color:#24292E;"> }</span></span>
<span class="line"></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#6A737D;">// Enable line numbers in code block.</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#E36209;">lineNumbers</span><span style="color:#D73A49;">?:</span><span style="color:#24292E;"> </span><span style="color:#005CC5;">boolean</span></span>
<span class="line"></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#6A737D;">// Add support for your own languages.</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#6A737D;">// https://github.com/shikijs/shiki/blob/main/docs/languages.md#supporting-your-own-languages-with-shiki</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#E36209;">languages</span><span style="color:#D73A49;">?:</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">Shiki</span><span style="color:#24292E;">.</span><span style="color:#6F42C1;">ILanguageRegistration</span></span>
<span class="line"></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#6A737D;">// markdown-it-anchor plugin options.</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#6A737D;">// See: https://github.com/valeriangalliat/markdown-it-anchor#usage</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#E36209;">anchor</span><span style="color:#D73A49;">?:</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">anchorPlugin</span><span style="color:#24292E;">.</span><span style="color:#6F42C1;">AnchorOptions</span></span>
<span class="line"></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#6A737D;">// markdown-it-attrs plugin options.</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#6A737D;">// See: https://github.com/arve0/markdown-it-attrs</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#E36209;">attrs</span><span style="color:#D73A49;">?:</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">		</span><span style="color:#E36209;">leftDelimiter</span><span style="color:#D73A49;">?:</span><span style="color:#24292E;"> </span><span style="color:#005CC5;">string</span></span>
<span class="line"><span style="color:#24292E;">		</span><span style="color:#E36209;">rightDelimiter</span><span style="color:#D73A49;">?:</span><span style="color:#24292E;"> </span><span style="color:#005CC5;">string</span></span>
<span class="line"><span style="color:#24292E;">		</span><span style="color:#E36209;">allowedAttributes</span><span style="color:#D73A49;">?:</span><span style="color:#24292E;"> </span><span style="color:#005CC5;">string</span><span style="color:#24292E;">[]</span></span>
<span class="line"><span style="color:#24292E;">		</span><span style="color:#E36209;">disable</span><span style="color:#D73A49;">?:</span><span style="color:#24292E;"> </span><span style="color:#005CC5;">boolean</span></span>
<span class="line"><span style="color:#24292E;">	}</span></span>
<span class="line"></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#6A737D;">// specify default language for syntax highlighter</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#E36209;">defaultHighlightLang</span><span style="color:#D73A49;">?:</span><span style="color:#24292E;"> </span><span style="color:#005CC5;">string</span></span>
<span class="line"></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#6A737D;">// @mdit-vue/plugin-frontmatter plugin options.</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#6A737D;">// See: https://github.com/mdit-vue/mdit-vue/tree/main/packages/plugin-frontmatter#options</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#E36209;">frontmatter</span><span style="color:#D73A49;">?:</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">FrontmatterPluginOptions</span></span>
<span class="line"></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#6A737D;">// @mdit-vue/plugin-headers plugin options.</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#6A737D;">// See: https://github.com/mdit-vue/mdit-vue/tree/main/packages/plugin-headers#options</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#E36209;">headers</span><span style="color:#D73A49;">?:</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">HeadersPluginOptions</span></span>
<span class="line"></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#6A737D;">// @mdit-vue/plugin-sfc plugin options.</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#6A737D;">// See: https://github.com/mdit-vue/mdit-vue/tree/main/packages/plugin-sfc#options</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#E36209;">sfc</span><span style="color:#D73A49;">?:</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">SfcPluginOptions</span></span>
<span class="line"></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#6A737D;">// @mdit-vue/plugin-toc plugin options.</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#6A737D;">// See: https://github.com/mdit-vue/mdit-vue/tree/main/packages/plugin-toc#options</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#E36209;">toc</span><span style="color:#D73A49;">?:</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">TocPluginOptions</span></span>
<span class="line"></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#6A737D;">// Configure the Markdown-it instance.</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#6F42C1;">config</span><span style="color:#D73A49;">?:</span><span style="color:#24292E;"> (</span><span style="color:#E36209;">md</span><span style="color:#D73A49;">:</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">MarkdownIt</span><span style="color:#24292E;">) </span><span style="color:#D73A49;">=&gt;</span><span style="color:#24292E;"> </span><span style="color:#005CC5;">void</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br><span class="line-number">6</span><br><span class="line-number">7</span><br><span class="line-number">8</span><br><span class="line-number">9</span><br><span class="line-number">10</span><br><span class="line-number">11</span><br><span class="line-number">12</span><br><span class="line-number">13</span><br><span class="line-number">14</span><br><span class="line-number">15</span><br><span class="line-number">16</span><br><span class="line-number">17</span><br><span class="line-number">18</span><br><span class="line-number">19</span><br><span class="line-number">20</span><br><span class="line-number">21</span><br><span class="line-number">22</span><br><span class="line-number">23</span><br><span class="line-number">24</span><br><span class="line-number">25</span><br><span class="line-number">26</span><br><span class="line-number">27</span><br><span class="line-number">28</span><br><span class="line-number">29</span><br><span class="line-number">30</span><br><span class="line-number">31</span><br><span class="line-number">32</span><br><span class="line-number">33</span><br><span class="line-number">34</span><br><span class="line-number">35</span><br><span class="line-number">36</span><br><span class="line-number">37</span><br><span class="line-number">38</span><br><span class="line-number">39</span><br><span class="line-number">40</span><br><span class="line-number">41</span><br><span class="line-number">42</span><br><span class="line-number">43</span><br><span class="line-number">44</span><br><span class="line-number">45</span><br><span class="line-number">46</span><br><span class="line-number">47</span><br><span class="line-number">48</span><br><span class="line-number">49</span><br><span class="line-number">50</span><br></div></div><h3 id="vite" tabindex="-1">vite <a class="header-anchor" href="#vite" aria-label="Permalink to &quot;vite&quot;">​</a></h3><ul><li>key: <code>vite</code></li><li>Type: <code>import(&#39;vite&#39;).UserConfig</code></li></ul><p>将原始 <a href="https://vitejs.dev/config/" target="_blank" rel="noreferrer">Vite 配置</a>传递给内部 Vite 开发服务器 / bundler。</p><div class="language-js vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">js</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	vite: {</span></span>
<span class="line"><span style="color:#E1E4E8;">		</span><span style="color:#6A737D;">// Vite config options</span></span>
<span class="line"><span style="color:#E1E4E8;">	},</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	vite: {</span></span>
<span class="line"><span style="color:#24292E;">		</span><span style="color:#6A737D;">// Vite config options</span></span>
<span class="line"><span style="color:#24292E;">	},</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br></div></div><h3 id="vue" tabindex="-1">vue <a class="header-anchor" href="#vue" aria-label="Permalink to &quot;vue&quot;">​</a></h3><ul><li>key: <code>vue</code></li><li>Type: <code>import(&#39;@vitejs/plugin-vue&#39;).Options</code></li></ul><p>将原始的 <a href="https://github.com/vitejs/vite-plugin-vue/tree/main/packages/plugin-vue#options" target="_blank" rel="noreferrer">@vitejs/plugin-vue 选项</a>传递给内部插件实例。</p><div class="language-js vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">js</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	vue: {</span></span>
<span class="line"><span style="color:#E1E4E8;">		</span><span style="color:#6A737D;">// @vitejs/plugin-vue options</span></span>
<span class="line"><span style="color:#E1E4E8;">	},</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	vue: {</span></span>
<span class="line"><span style="color:#24292E;">		</span><span style="color:#6A737D;">// @vitejs/plugin-vue options</span></span>
<span class="line"><span style="color:#24292E;">	},</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br></div></div><h2 id="build-hooks" tabindex="-1">构建钩子 <a class="header-anchor" href="#build-hooks" aria-label="Permalink to &quot;构建钩子 {#build-hooks}&quot;">​</a></h2><p>VitePress build hooks allow you to add new functionality and behaviors to your website: VitePress 构建钩子允许你向你的网站添加新功能和行为：</p><ul><li>Sitemap 网站地图</li><li>Search Indexing 搜索索引</li><li>PWA 渐进式网页应用</li><li>Teleports 传送门</li></ul><h3 id="buildend" tabindex="-1">buildEnd <a class="header-anchor" href="#buildend" aria-label="Permalink to &quot;buildEnd&quot;">​</a></h3><ul><li>key: <code>buildEnd</code></li><li>Type: <code>(siteConfig: SiteConfig) =&gt; Awaitable&lt;void&gt;</code></li></ul><p><code>buildEnd</code> 是一个构建 CLI 钩子，它将在构建（SSG）完成后但在 VitePress CLI 进程退出之前运行。</p><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#F97583;">async</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">buildEnd</span><span style="color:#E1E4E8;">(</span><span style="color:#FFAB70;">siteConfig</span><span style="color:#E1E4E8;">) {</span></span>
<span class="line"><span style="color:#E1E4E8;">		</span><span style="color:#6A737D;">// ...</span></span>
<span class="line"><span style="color:#E1E4E8;">	},</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#D73A49;">async</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">buildEnd</span><span style="color:#24292E;">(</span><span style="color:#E36209;">siteConfig</span><span style="color:#24292E;">) {</span></span>
<span class="line"><span style="color:#24292E;">		</span><span style="color:#6A737D;">// ...</span></span>
<span class="line"><span style="color:#24292E;">	},</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br></div></div><h3 id="postrender" tabindex="-1">postRender <a class="header-anchor" href="#postrender" aria-label="Permalink to &quot;postRender&quot;">​</a></h3><ul><li>key: <code>postRender</code></li><li>Type: <code>(context: SSGContext) =&gt; Awaitable&lt;SSGContext | void&gt;</code></li></ul><details class="details custom-block"><summary><code>postRender</code> 是一个构建钩子，在 SSG 渲染完成时调用。它将允许你在 SSG(静态站点生成) 期间处理传递的内容。</summary><p><code>postRender</code> is a build hook, called when SSG rendering is done. It will allow you to handle the teleports content during SSG.</p></details><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#F97583;">async</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">postRender</span><span style="color:#E1E4E8;">(</span><span style="color:#FFAB70;">context</span><span style="color:#E1E4E8;">) {</span></span>
<span class="line"><span style="color:#E1E4E8;">		</span><span style="color:#6A737D;">// ...</span></span>
<span class="line"><span style="color:#E1E4E8;">	},</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#D73A49;">async</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">postRender</span><span style="color:#24292E;">(</span><span style="color:#E36209;">context</span><span style="color:#24292E;">) {</span></span>
<span class="line"><span style="color:#24292E;">		</span><span style="color:#6A737D;">// ...</span></span>
<span class="line"><span style="color:#24292E;">	},</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br></div></div><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">interface</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">SSGContext</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#FFAB70;">content</span><span style="color:#F97583;">:</span><span style="color:#E1E4E8;"> </span><span style="color:#79B8FF;">string</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#FFAB70;">teleports</span><span style="color:#F97583;">?:</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">Record</span><span style="color:#E1E4E8;">&lt;</span><span style="color:#79B8FF;">string</span><span style="color:#E1E4E8;">, </span><span style="color:#79B8FF;">string</span><span style="color:#E1E4E8;">&gt;</span></span>
<span class="line"><span style="color:#E1E4E8;">	[key: string]</span><span style="color:#F97583;">:</span><span style="color:#E1E4E8;"> </span><span style="color:#79B8FF;">any</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">interface</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">SSGContext</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#E36209;">content</span><span style="color:#D73A49;">:</span><span style="color:#24292E;"> </span><span style="color:#005CC5;">string</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#E36209;">teleports</span><span style="color:#D73A49;">?:</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">Record</span><span style="color:#24292E;">&lt;</span><span style="color:#005CC5;">string</span><span style="color:#24292E;">, </span><span style="color:#005CC5;">string</span><span style="color:#24292E;">&gt;</span></span>
<span class="line"><span style="color:#24292E;">	[key: string]</span><span style="color:#D73A49;">:</span><span style="color:#24292E;"> </span><span style="color:#005CC5;">any</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br></div></div><h3 id="transformhead" tabindex="-1">transformHead <a class="header-anchor" href="#transformhead" aria-label="Permalink to &quot;transformHead&quot;">​</a></h3><ul><li>key: <code>transformHead</code></li><li>Type: <code>(context: TransformContext) =&gt; Awaitable&lt;HeadConfig[]&gt;</code></li></ul><p><code>transformHead</code> 是一个构建钩子，用于在生成每个页面之前转换 head。它将允许你添加无法静态添加到你的 VitePress 配置中的 head entries。你只需要返回额外的 entries，它们将自动与现有 entries 合并。</p><div class="warning custom-block"><p class="custom-block-title">警告</p><p>不要改变 <code>ctx</code> 中的任何东西。</p></div><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#F97583;">async</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">transformHead</span><span style="color:#E1E4E8;">(</span><span style="color:#FFAB70;">context</span><span style="color:#E1E4E8;">) {</span></span>
<span class="line"><span style="color:#E1E4E8;">		</span><span style="color:#6A737D;">// ...</span></span>
<span class="line"><span style="color:#E1E4E8;">	},</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#D73A49;">async</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">transformHead</span><span style="color:#24292E;">(</span><span style="color:#E36209;">context</span><span style="color:#24292E;">) {</span></span>
<span class="line"><span style="color:#24292E;">		</span><span style="color:#6A737D;">// ...</span></span>
<span class="line"><span style="color:#24292E;">	},</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br></div></div><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">interface</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">TransformContext</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#FFAB70;">page</span><span style="color:#F97583;">:</span><span style="color:#E1E4E8;"> </span><span style="color:#79B8FF;">string</span><span style="color:#E1E4E8;"> </span><span style="color:#6A737D;">// e.g. index.md (relative to srcDir)</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#FFAB70;">assets</span><span style="color:#F97583;">:</span><span style="color:#E1E4E8;"> </span><span style="color:#79B8FF;">string</span><span style="color:#E1E4E8;">[] </span><span style="color:#6A737D;">// all non-js/css assets as fully resolved public URL</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#FFAB70;">siteConfig</span><span style="color:#F97583;">:</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">SiteConfig</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#FFAB70;">siteData</span><span style="color:#F97583;">:</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">SiteData</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#FFAB70;">pageData</span><span style="color:#F97583;">:</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">PageData</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#FFAB70;">title</span><span style="color:#F97583;">:</span><span style="color:#E1E4E8;"> </span><span style="color:#79B8FF;">string</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#FFAB70;">description</span><span style="color:#F97583;">:</span><span style="color:#E1E4E8;"> </span><span style="color:#79B8FF;">string</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#FFAB70;">head</span><span style="color:#F97583;">:</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">HeadConfig</span><span style="color:#E1E4E8;">[]</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#FFAB70;">content</span><span style="color:#F97583;">:</span><span style="color:#E1E4E8;"> </span><span style="color:#79B8FF;">string</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">interface</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">TransformContext</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#E36209;">page</span><span style="color:#D73A49;">:</span><span style="color:#24292E;"> </span><span style="color:#005CC5;">string</span><span style="color:#24292E;"> </span><span style="color:#6A737D;">// e.g. index.md (relative to srcDir)</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#E36209;">assets</span><span style="color:#D73A49;">:</span><span style="color:#24292E;"> </span><span style="color:#005CC5;">string</span><span style="color:#24292E;">[] </span><span style="color:#6A737D;">// all non-js/css assets as fully resolved public URL</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#E36209;">siteConfig</span><span style="color:#D73A49;">:</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">SiteConfig</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#E36209;">siteData</span><span style="color:#D73A49;">:</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">SiteData</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#E36209;">pageData</span><span style="color:#D73A49;">:</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">PageData</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#E36209;">title</span><span style="color:#D73A49;">:</span><span style="color:#24292E;"> </span><span style="color:#005CC5;">string</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#E36209;">description</span><span style="color:#D73A49;">:</span><span style="color:#24292E;"> </span><span style="color:#005CC5;">string</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#E36209;">head</span><span style="color:#D73A49;">:</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">HeadConfig</span><span style="color:#24292E;">[]</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#E36209;">content</span><span style="color:#D73A49;">:</span><span style="color:#24292E;"> </span><span style="color:#005CC5;">string</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br><span class="line-number">6</span><br><span class="line-number">7</span><br><span class="line-number">8</span><br><span class="line-number">9</span><br><span class="line-number">10</span><br><span class="line-number">11</span><br></div></div><h3 id="transformhtml" tabindex="-1">transformHtml <a class="header-anchor" href="#transformhtml" aria-label="Permalink to &quot;transformHtml&quot;">​</a></h3><ul><li>key: <code>transformHtml</code></li><li>Type: <code>(code: string, id: string, ctx: TransformContext) =&gt; Awaitable&lt;string | void&gt;</code></li></ul><p><code>transformHtml</code> 是一个构建钩子，用于在保存到磁盘之前转换每个页面的内容。</p><div class="warning custom-block"><p class="custom-block-title">警告</p><p>不要改变 <code>ctx</code> 中的任何东西。另外，修改 html 内容可能会导致运行时出现 hydration 问题。</p></div><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#F97583;">async</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">transformHtml</span><span style="color:#E1E4E8;">(</span><span style="color:#FFAB70;">code</span><span style="color:#E1E4E8;">, </span><span style="color:#FFAB70;">id</span><span style="color:#E1E4E8;">, </span><span style="color:#FFAB70;">context</span><span style="color:#E1E4E8;">) {</span></span>
<span class="line"><span style="color:#E1E4E8;">		</span><span style="color:#6A737D;">// ...</span></span>
<span class="line"><span style="color:#E1E4E8;">	},</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#D73A49;">async</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">transformHtml</span><span style="color:#24292E;">(</span><span style="color:#E36209;">code</span><span style="color:#24292E;">, </span><span style="color:#E36209;">id</span><span style="color:#24292E;">, </span><span style="color:#E36209;">context</span><span style="color:#24292E;">) {</span></span>
<span class="line"><span style="color:#24292E;">		</span><span style="color:#6A737D;">// ...</span></span>
<span class="line"><span style="color:#24292E;">	},</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br></div></div><h3 id="transformpagedata" tabindex="-1">transformPageData <a class="header-anchor" href="#transformpagedata" aria-label="Permalink to &quot;transformPageData&quot;">​</a></h3><ul><li>key: <code>transformPageData</code></li><li>Type: <code>(pageData: PageData, ctx: TransformPageContext) =&gt; Awaitable&lt;Partial&lt;PageData&gt; | { [key: string]: any } | void&gt;</code></li></ul><p><code>transformPageData</code> 是一个钩子，用于转换每个页面的 <code>pageData</code>。你可以直接改变 <code>pageData</code> 或返回将合并到 <code>PageData</code> 中的更改值。</p><div class="warning custom-block"><p class="custom-block-title">警告</p><p>不要改变 <code>ctx</code> 中的任何东西。</p></div><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">export</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">default</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">  </span><span style="color:#F97583;">async</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">transformPageData</span><span style="color:#E1E4E8;">(</span><span style="color:#FFAB70;">pageData</span><span style="color:#E1E4E8;">, { </span><span style="color:#FFAB70;">siteConfig</span><span style="color:#E1E4E8;"> }) {</span></span>
<span class="line"><span style="color:#E1E4E8;">    pageData.contributors </span><span style="color:#F97583;">=</span><span style="color:#E1E4E8;"> </span><span style="color:#F97583;">await</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">getPageContributors</span><span style="color:#E1E4E8;">(pageData.relativePath)</span></span>
<span class="line"><span style="color:#E1E4E8;">  }</span></span>
<span class="line"></span>
<span class="line"><span style="color:#E1E4E8;">  </span><span style="color:#6A737D;">// or return data to be merged</span></span>
<span class="line"><span style="color:#E1E4E8;">  </span><span style="color:#F97583;">async</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">transformPageData</span><span style="color:#E1E4E8;">(</span><span style="color:#FFAB70;">pageData</span><span style="color:#E1E4E8;">, { </span><span style="color:#FFAB70;">siteConfig</span><span style="color:#E1E4E8;"> }) {</span></span>
<span class="line"><span style="color:#E1E4E8;">    </span><span style="color:#F97583;">return</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">      contributors: </span><span style="color:#F97583;">await</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">getPageContributors</span><span style="color:#E1E4E8;">(pageData.relativePath)</span></span>
<span class="line"><span style="color:#E1E4E8;">    }</span></span>
<span class="line"><span style="color:#E1E4E8;">  }</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">export</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">default</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">  </span><span style="color:#D73A49;">async</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">transformPageData</span><span style="color:#24292E;">(</span><span style="color:#E36209;">pageData</span><span style="color:#24292E;">, { </span><span style="color:#E36209;">siteConfig</span><span style="color:#24292E;"> }) {</span></span>
<span class="line"><span style="color:#24292E;">    pageData.contributors </span><span style="color:#D73A49;">=</span><span style="color:#24292E;"> </span><span style="color:#D73A49;">await</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">getPageContributors</span><span style="color:#24292E;">(pageData.relativePath)</span></span>
<span class="line"><span style="color:#24292E;">  }</span></span>
<span class="line"></span>
<span class="line"><span style="color:#24292E;">  </span><span style="color:#6A737D;">// or return data to be merged</span></span>
<span class="line"><span style="color:#24292E;">  </span><span style="color:#D73A49;">async</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">transformPageData</span><span style="color:#24292E;">(</span><span style="color:#E36209;">pageData</span><span style="color:#24292E;">, { </span><span style="color:#E36209;">siteConfig</span><span style="color:#24292E;"> }) {</span></span>
<span class="line"><span style="color:#24292E;">    </span><span style="color:#D73A49;">return</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">      contributors: </span><span style="color:#D73A49;">await</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">getPageContributors</span><span style="color:#24292E;">(pageData.relativePath)</span></span>
<span class="line"><span style="color:#24292E;">    }</span></span>
<span class="line"><span style="color:#24292E;">  }</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br><span class="line-number">4</span><br><span class="line-number">5</span><br><span class="line-number">6</span><br><span class="line-number">7</span><br><span class="line-number">8</span><br><span class="line-number">9</span><br><span class="line-number">10</span><br><span class="line-number">11</span><br><span class="line-number">12</span><br></div></div><div class="language-ts vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">ts</span><pre class="shiki github-dark vp-code-dark"><code><span class="line"><span style="color:#F97583;">interface</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">TransformPageContext</span><span style="color:#E1E4E8;"> {</span></span>
<span class="line"><span style="color:#E1E4E8;">	</span><span style="color:#FFAB70;">siteConfig</span><span style="color:#F97583;">:</span><span style="color:#E1E4E8;"> </span><span style="color:#B392F0;">SiteConfig</span></span>
<span class="line"><span style="color:#E1E4E8;">}</span></span></code></pre><pre class="shiki github-light vp-code-light"><code><span class="line"><span style="color:#D73A49;">interface</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">TransformPageContext</span><span style="color:#24292E;"> {</span></span>
<span class="line"><span style="color:#24292E;">	</span><span style="color:#E36209;">siteConfig</span><span style="color:#D73A49;">:</span><span style="color:#24292E;"> </span><span style="color:#6F42C1;">SiteConfig</span></span>
<span class="line"><span style="color:#24292E;">}</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br><span class="line-number">3</span><br></div></div></div></div></main><footer class="VPDocFooter" data-v-6b87e69f data-v-ef5dee53><!--[--><!--]--><div class="edit-info" data-v-ef5dee53><div class="edit-link" data-v-ef5dee53><a class="VPLink link vp-external-link-icon no-icon edit-link-button" href="https://github.com/vanchKong/VitePressCN/edit/main/docs/examples/md/site-config.md" target="_blank" rel="noreferrer" data-v-ef5dee53><!--[--><svg xmlns="http://www.w3.org/2000/svg" viewbox="0 0 24 24" class="edit-link-icon" aria-label="edit icon" data-v-ef5dee53><path d="M18,23H4c-1.7,0-3-1.3-3-3V6c0-1.7,1.3-3,3-3h7c0.6,0,1,0.4,1,1s-0.4,1-1,1H4C3.4,5,3,5.4,3,6v14c0,0.6,0.4,1,1,1h14c0.6,0,1-0.4,1-1v-7c0-0.6,0.4-1,1-1s1,0.4,1,1v7C21,21.7,19.7,23,18,23z"></path><path d="M8,17c-0.3,0-0.5-0.1-0.7-0.3C7,16.5,6.9,16.1,7,15.8l1-4c0-0.2,0.1-0.3,0.3-0.5l9.5-9.5c1.2-1.2,3.2-1.2,4.4,0c1.2,1.2,1.2,3.2,0,4.4l-9.5,9.5c-0.1,0.1-0.3,0.2-0.5,0.3l-4,1C8.2,17,8.1,17,8,17zM9.9,12.5l-0.5,2.1l2.1-0.5l9.3-9.3c0.4-0.4,0.4-1.1,0-1.6c-0.4-0.4-1.2-0.4-1.6,0l0,0L9.9,12.5z M18.5,2.5L18.5,2.5L18.5,2.5z"></path></svg> 在GitHub上编辑此页<!--]--></a></div><!----></div><nav class="prev-next" data-v-ef5dee53><div class="pager" data-v-ef5dee53><!----></div><div class="pager" data-v-ef5dee53><a class="pager-link next" href="/examples/md/frontmatter-config" data-v-ef5dee53><span class="desc" data-v-ef5dee53>下一篇</span><span class="title" data-v-ef5dee53>Frontmatter 配置</span></a></div></nav></footer><!--[--><!--]--></div></div></div><!--[--><!--]--></div></div><footer class="VPFooter has-sidebar" data-v-5a346dfe data-v-e03eb2e1><div class="container" data-v-e03eb2e1><p class="message" data-v-e03eb2e1>Released under the MIT License.</p><p class="copyright" data-v-e03eb2e1>Copyright 2023 www.56jzt.com</p></div></footer><!--[--><!--]--></div></div>
    <script>window.__VP_HASH_MAP__=JSON.parse("{\"examples_md_default-theme-footer.md\":\"4c8afdbd\",\"readme.md\":\"5d3c33ea\",\"examples_md_cli.md\":\"c73cd1be\",\"guide_demo-button.md\":\"4a8d5d4f\",\"examples_md_team.md\":\"19fcceea\",\"examples_md_default-theme-last-updated.md\":\"d168b138\",\"guide_cms.md\":\"c87e0998\",\"examples_md_default-theme-team-page.md\":\"81ecf5fd\",\"guide_migration-from-vitepress-0.md\":\"a9ec5ec4\",\"examples_md_frontmatter-config.md\":\"4118570a\",\"guide_deploy.md\":\"bcb72ef1\",\"examples_md_default-theme-edit-link.md\":\"24c88a65\",\"examples_md_default-theme-layout.md\":\"9db32ddd\",\"examples_md_default-theme-nav.md\":\"163472c8\",\"index.md\":\"f1c49fc9\",\"guide_what-is-vitepress.md\":\"ed98d1c4\",\"guide_markdown-base.md\":\"d2a42559\",\"examples_md_default-theme-carbon-ads.md\":\"2bf745b5\",\"guide_asset-handling.md\":\"7559e329\",\"examples_md_default-theme-home-page.md\":\"146eea41\",\"api-examples.md\":\"9c024793\",\"examples_md_default-theme-prev-next-links.md\":\"02be0bc3\",\"examples_md_default-theme-search.md\":\"64dd3a5c\",\"versionlog_v1.0.1.md\":\"fbaa2430\",\"guide_using-vue.md\":\"5c41f617\",\"markdown-examples.md\":\"16c217af\",\"versionlog_v1.0.0.md\":\"676fa2b0\",\"versionlog_v1.0.2.md\":\"1191b553\",\"guide_data-loading.md\":\"75b38ad5\",\"guide_sitemap-generation.md\":\"2ab6510e\",\"guide_migration-from-vuepress.md\":\"1548f7ea\",\"guide_extending-default-theme.md\":\"bda7ecd8\",\"guide_i18n.md\":\"d78c79a7\",\"examples_md_site-config.md\":\"b89a013d\",\"examples_md_runtime-api.md\":\"fcb02c2a\",\"examples_md_default-theme-sidebar.md\":\"02e3db56\",\"examples_md_default-theme-badge.md\":\"0b59ca30\",\"guide_mpa-mode.md\":\"6f9bc7f9\",\"guide_frontmatter.md\":\"1ab639ee\",\"guide_getting-started.md\":\"38d77576\",\"examples_md_default-theme-config.md\":\"3e21dc9f\",\"guide_routing.md\":\"aed61575\",\"guide_custom-theme.md\":\"64c16a6e\",\"guide_ssr-compat.md\":\"292538a0\",\"guide_markdown.md\":\"09458916\"}");window.__VP_SITE_DATA__=JSON.parse("{\"lang\":\"zh-CN\",\"dir\":\"ltr\",\"title\":\"九州通物流\",\"description\":\"Vite & Vue 驱动的静态站点生成器\",\"base\":\"/\",\"head\":[],\"appearance\":true,\"themeConfig\":{\"lastUpdated\":{\"text\":\"最近更新时间\",\"formatOptions\":{\"dateStyle\":\"short\",\"timeStyle\":\"medium\"}},\"darkModeSwitchLabel\":\"主题\",\"sidebarMenuLabel\":\"菜单\",\"returnToTopLabel\":\"回到顶部\",\"langMenuLabel\":\"多语言\",\"externalLinkIcon\":true,\"outlineTitle\":\"当前页\",\"logo\":\"/logo.ico\",\"siteTitle\":\"云仓组件库\",\"docFooter\":{\"prev\":\"上一篇\",\"next\":\"下一篇\"},\"nav\":[{\"text\":\"接入指南\",\"link\":\"/guide/what-is-vitepress\",\"activeMatch\":\"/guide/\"},{\"text\":\"组件配置\",\"link\":\"/examples/md/site-config\",\"activeMatch\":\"/examples/\"},{\"text\":\"版本日志\",\"link\":\"/versionLog/v1.0.2\",\"activeMatch\":\"/versionLog/\"}],\"sidebar\":{\"/guide/\":[{\"text\":\"介绍\",\"collapsed\":true,\"items\":[{\"text\":\"设计初衷\",\"link\":\"/guide/what-is-vitepress\"},{\"text\":\"使用安装\",\"link\":\"/guide/getting-started\"},{\"text\":\"快速开始\",\"link\":\"/guide/routing\"},{\"text\":\"按需引入\",\"link\":\"/guide/sitemap-generation\"}]},{\"text\":\"本地开发\",\"collapsed\":true,\"items\":[{\"text\":\"编写新组件\",\"link\":\"/guide/markdown-base\"},{\"text\":\"编写测试用例\",\"link\":\"/guide/markdown\"},{\"text\":\"编写API文档\",\"link\":\"/guide/asset-handling\"},{\"text\":\"修改版本号\",\"link\":\"/guide/frontmatter\"},{\"text\":\"打包构建组件库\",\"link\":\"/guide/using-vue\"},{\"text\":\"上传组件库到npm仓库\",\"link\":\"/guide/i18n\"},{\"text\":\"更新组件文档\",\"link\":\"/guide/i18n\"}]},{\"text\":\"组件示例 & API 参考\",\"link\":\"/examples/md/site-config\"}],\"/examples/\":[{\"text\":\"参考\",\"items\":[{\"text\":\"站点配置\",\"link\":\"/examples/md/site-config\"},{\"text\":\"Frontmatter 配置\",\"link\":\"/examples/md/frontmatter-config\"},{\"text\":\"Runtime API\",\"link\":\"/examples/md/runtime-api\"},{\"text\":\"CLI\",\"link\":\"/examples/md/cli\"},{\"text\":\"默认主题\",\"items\":[{\"text\":\"概览\",\"link\":\"/examples/md/default-theme-config\"},{\"text\":\"导航栏\",\"link\":\"/examples/md/default-theme-nav\"},{\"text\":\"侧边栏\",\"link\":\"/examples/md/default-theme-sidebar\"},{\"text\":\"主页\",\"link\":\"/examples/md/default-theme-home-page\"},{\"text\":\"页脚\",\"link\":\"/examples/md/default-theme-footer\"},{\"text\":\"布局\",\"link\":\"/examples/md/default-theme-layout\"},{\"text\":\"徽标\",\"link\":\"/examples/md/default-theme-badge\"},{\"text\":\"团队\",\"link\":\"/examples/md/default-theme-team-page\"},{\"text\":\"上（下）一篇\",\"link\":\"/examples/md/default-theme-prev-next-links\"},{\"text\":\"编辑链接\",\"link\":\"/examples/md/default-theme-edit-link\"},{\"text\":\"最近更新时间\",\"link\":\"/examples/md/default-theme-last-updated\"},{\"text\":\"搜索\",\"link\":\"/examples/md/default-theme-search\"},{\"text\":\"Carbon Ads\",\"link\":\"/examples/md/default-theme-carbon-ads\"}]}]}],\"/versionLog/\":[{\"text\":\"日志\",\"items\":[{\"text\":\"v1.0.2\",\"link\":\"/versionLog/v1.0.2\"},{\"text\":\"v1.0.1\",\"link\":\"/versionLog/v1.0.1\"},{\"text\":\"v1.0.0\",\"link\":\"/versionLog/v1.0.0\"}]}]},\"socialLinks\":[{\"icon\":\"github\",\"link\":\"https://github.com/vanchKong/VitePressCN\"}],\"editLink\":{\"text\":\"在GitHub上编辑此页\",\"pattern\":\"https://github.com/vanchKong/VitePressCN/edit/main/docs/:path\"},\"footer\":{\"message\":\"Released under the MIT License.\",\"copyright\":\"Copyright 2023 www.56jzt.com\"},\"search\":{\"provider\":\"local\"}},\"locales\":{},\"scrollOffset\":90,\"cleanUrls\":true}");</script>
    
  </body>
</html>